VSCodeVim / Vim

:star: Vim for Visual Studio Code
http://aka.ms/vscodevim
MIT License
13.94k stars 1.32k forks source link

Failed to handle key `u`: TextEditor(vs.editor.ICodeEditor:1,$model25) has been disposed #8250

Open JIHernandez13 opened 1 year ago

JIHernandez13 commented 1 year ago

To Reproduce Steps to reproduce the behavior:

  1. Go to any file
  2. Click on 'u'
  3. Sometimes, the plugin will start entering new lines everywhere
  4. Close the file to see the error.

VSCodeVim version: 1.24.3

Stack trace ``` DISPOSED: TextEditor(vs.editor.ICodeEditor:1,$model25) has been disposed at g (vscode-file://vscode-app/c:/Users/JesusHernandez/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:10:1616) at uc.$tryApplyEdits (vscode-file://vscode-app/c:/Users/JesusHernandez/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:2299:13996) at m.N (vscode-file://vscode-app/c:/Users/JesusHernandez/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1573:15220) at m.M (vscode-file://vscode-app/c:/Users/JesusHernandez/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1573:14938) at m.H (vscode-file://vscode-app/c:/Users/JesusHernandez/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1573:14031) at m.G (vscode-file://vscode-app/c:/Users/JesusHernandez/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1573:13012) at vscode-file://vscode-app/c:/Users/JesusHernandez/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1573:11800 at g.invoke (vscode-file://vscode-app/c:/Users/JesusHernandez/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:86:145) at n.deliver (vscode-file://vscode-app/c:/Users/JesusHernandez/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:86:2029) at a.fire (vscode-file://vscode-app/c:/Users/JesusHernandez/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:86:1667) at r.fire (vscode-file://vscode-app/c:/Users/JesusHernandez/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:553:15219) at Z.onmessage (vscode-file://vscode-app/c:/Users/JesusHernandez/AppData/Local/Programs/Microsoft VS Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1671:1490) ```

Sometimes pressing 'u' on windows puts newlines everywhere. Seems to be intermittent, unsure why this takes place but it's mildly annoying to deal with.

The only quick remedy I had is to close the file quickly and revert the newline changes. It starts at the bottom of the file regardless of where I press 'u'.

image

a1eaiactaest commented 1 year ago

Probably related to #8157.