Vim stops working unexpectedly (issues collection)

Created on 16 Jul 2016  路  7Comments  路  Source: VSCodeVim/Vim

Technical details:

  • VSCode Version: 1.4.0-Insider
  • VsCodeVim Version: 0.1.2
  • OS: Windows 10 x64

For now I can' repro this constantly but I've ran into the issues dozens of times. Our extension suddenly stops working (can't not move cursor or perform any command any more) sometimes switching Tab. Below is the error log in console.

Object__proto__: Object  reason:  RangeError
    at Function.readLineAt (C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\textEditor.js:82:19)
    at Function.getLineLength (C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\motion\position.js:316:40)
    at Position.getLineEnd (C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\motion\position.js:244:49)
    at ModeHandler.<anonymous> (C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\mode\modeHandler.js:341:58)
    at next (native)
    at C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\mode\modeHandler.js:7:65
    at __awaiter (C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\mode\modeHandler.js:3:12)
    at ModeHandler.vscode.window.onDidChangeTextEditorSelection (C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\mode\modeHandler.js:320:61)
    at e.invoke (c:\Program Files (x86)\Microsoft VS Code Insiders\resources\app\out\vs\workbench\node\extensionHostProcess.js:6:24776)
    at e.fire (c:\Program Files (x86)\Microsoft VS Code Insiders\resources\app\out\vs\workbench\node\extensionHostProcess.js:6:26824)
    at t.$acceptSelectionsChanged (c:\Program Files (x86)\Microsoft VS Code Insiders\resources\app\out\vs\workbench\node\extensionHostProcess.js:10:28226)

I'd like to raise this issue first and put more info once I found the root cause. If anyone else sees this problem as well, please let us know.

All 7 comments

Very weird. I have never run into this issue, and I use this extension pretty much every day at work.

Could it possibly be due to other extensions you have installed? Also, which languages do you edit with VSCodeVim?

It's typescript and our Vim project I was working on. I ran into problem several times when I was using Mac but met it again these days when I started to use Windows and Vim and Chrome debug are the only extensions I installed

Ran into another failure, this seems possible as we don't always check if activeTextEditor is null.

workbench.main.js:116 Cannot read property 'document' of undefined: TypeError: Cannot read property 'document' of undefined
    at Function.readLineAt (C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\textEditor.js:81:53)
    at Function.getLineLength (C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\motion\position.js:316:40)
    at Position.getLineEnd (C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\motion\position.js:244:49)
    at ModeHandler.<anonymous> (C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\mode\modeHandler.js:341:58)
    at next (native)
    at C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\mode\modeHandler.js:7:65
    at __awaiter (C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\mode\modeHandler.js:3:12)
    at ModeHandler.vscode.window.onDidChangeTextEditorSelection (C:\Users\cici\.vscode-insiders\extensions\vscodevim.vim-0.1.2\out\src\mode\modeHandler.js:320:61)
    at e.invoke (c:\Program Files (x86)\Microsoft VS Code Insiders\resources\app\out\vs\workbench\node\extensionHostProcess.js:6:24776)
    at e.fire (c:\Program Files (x86)\Microsoft VS Code Insiders\resources\app\out\vs\workbench\node\extensionHostProcess.js:6:26824)

I am also experience this issue. From time to time, and unpredictably, Vim bindings stop working.

Workaround

Restarting VS Code does not fix it. Uninstalling and reinstalling the Vim plugin does fix it.

VS Code Details

  • Visual Studio Code 1.4.0
  • Extensions: TSLint, C#, Vim.

Otherwise, this Vim extension is fantastic.

Edit: The problem was that I had Caps Lock on.

^ Restarting VSCode does not fix it?! Whoa...that seems bad.

Haha, thanks for the update @shaunluttin. Happens to everyone :)

Didn't run into this issue anymore for a long time (maybe 1 month or longer).

Was this page helpful?
0 / 5 - 0 ratings

Related issues

gerardmrk picture gerardmrk  路  3Comments

AndersenJ picture AndersenJ  路  3Comments

rajinder-yadav picture rajinder-yadav  路  3Comments

WangRongda picture WangRongda  路  3Comments

ACollectionOfAtoms picture ACollectionOfAtoms  路  3Comments