Failed to handle key `<C-a>`: Overlapping ranges are not allowed!
Open
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 15.2k
- Forks
- 1.5k
- Avg merge
- 3d 18h
- Merged PRs (30d)
- 6
Description
To Reproduce
Steps to reproduce the behavior:
- Go to '...'
- Click on '....'
- Scroll down to '....'
- See error
VSCodeVim version: 1.23.1
Stack trace
Error: Failed to handle key `<C-a>`: Overlapping ranges are not allowed!
at L._applyEdit (c:\Users\bender\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:83:55949)
at Object.edit (c:\Users\bender\AppData\Local\Programs\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:83:53600)
at executeTransformations (c:\Users\bender\.vscode\extensions\vscodevim.vim-1.23.1\src\transformations\execute.ts:111:31)
at N.runAction (c:\Users\bender\.vscode\extensions\vscodevim.vim-1.23.1\src\mode\modeHandler.ts:745:13)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at N.rerunRecordedState (c:\Users\bender\.vscode\extensions\vscodevim.vim-1.23.1\src\mode\modeHandler.ts:1112:55)
at transformer (c:\Users\bender\.vscode\extensions\vscodevim.vim-1.23.1\src\transformations\execute.ts:158:12)
at N.actionToRecord [as runAction] (c:\Users\bender\.vscode\extensions\vscodevim.vim-1.23.1\src\mode\modeHandler.ts:744:55)
at N.handledAsAction [as handleKeyAsAnAction] (c:\Users\bender\.vscode\extensions\vscodevim.vim-1.23.1\src\mode\modeHandler.ts:690:43)
at N.mh [as handleKeyEvent] (c:\Users\bender\.vscode\extensions\vscodevim.vim-1.23.1\src\mode\modeHandler.ts:507:11)
at r (c:\Users\bender\.vscode\extensions\vscodevim.vim-1.23.1\extensionBase.ts:488:15)
Additional context
currentMode: "Insert"
cursors: [
"[[3, 18] | [3, 18]]"
]
actionsRunPressedKeys: []
actionsRun: [
"B"
]
textTransformations: [
{
"type": "insertText",
"position": {
"line": 3,
"character": 18
},
"text": "",
"diff": {
"type": 0,
"line": 3,
"character": 6
},
"cursorIndex": 0
},
{
"type": "replaceText",
"range": [
{
"line": 3,
"character": 6
},
{
"line": 8,
"character": 32
}
],
"text": "",
"diff": {
"type": 0,
"line": 3,
"character": 6
},
"cursorIndex": 0
}
]
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in src/transformations/execute.ts at executeTransformations, then trace the action flow through src/mode/modeHandler.ts. Reproduce the failure with the recorded B action and inspect the overlapping insertText and replaceText transformations shown in the report. Done means handling this case without the “Overlapping ranges are not allowed!” error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- devtools
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100