Undo broken with new VS Code
Type: Bug
I just upgraded to VS Code 1.74.0 today, and started noticing an issue with undo command ("u") in Vim. It appears to only go back 2-3 iterations (my current Vim: History setting is "50"). And if I hit CTRL+Z, it first undoes what "u" just undid, then start actually undoing, e.g.
- i → insert mode
- a → "a"
- b → "ab"
- ESC → normal mode
- u → "a"
- u → nothing happens, but should've undone "a"
- CTRL-Z → "ab" (undoes what u just undid)
- CTRL-Z → "a"
- CTRL-Z → ""
Here is my VS Code info: Version: 1.74.0 (Universal) Commit: 5235c6bb189b60b01b1f49062f4ffa42384f8c91 Date: 2022-12-05T16:43:37.594Z (2 days ago) Electron: 19.1.8 Chromium: 102.0.5005.167 Node.js: 16.14.2 V8: 10.2.154.15-electron.0 OS: Darwin arm64 21.6.0 Sandboxed: No
Extension version: 1.24.3 VS Code version: Code 1.74.0 (Universal) (5235c6bb189b60b01b1f49062f4ffa42384f8c91, 2022-12-05T16:43:37.594Z) OS version: Darwin arm64 21.6.0 Modes: Sandboxed: No
System Info
| Item | Value |
|---|---|
| CPUs | Apple M1 Max (10 x 24) |
| GPU Status | 2d_canvas: enabled canvas_oop_rasterization: disabled_off direct_rendering_display_compositor: disabled_off_ok gpu_compositing: enabled metal: disabled_off multiple_raster_threads: enabled_on opengl: enabled_on rasterization: enabled raw_draw: disabled_off_ok skia_renderer: enabled_on video_decode: enabled video_encode: enabled vulkan: disabled_off webgl: enabled webgl2: enabled webgpu: disabled_off |
| Load (avg) | 2, 2, 2 |
| Memory (System) | 64.00GB (32.10GB free) |
| Process Argv | --crash-reporter-id 934e8b32-9713-4d8f-957f-354420e03177 |
| Screen Reader | yes |
| VM | 0% |
A/B Experiments
vsliv368:30146709
vsreu685:30147344
python383cf:30185419
vspor879:30202332
vspor708:30202333
vspor363:30204092
vslsvsres303:30308271
pythonvspyl392:30443607
vserr242cf:30382550
pythontb:30283811
vsjup518:30340749
pythonptprofiler:30281270
vsdfh931:30280409
vshan820:30294714
vstes263cf:30335440
vscoreces:30445986
pythondataviewer:30285071
vscod805cf:30301675
binariesv615:30325510
bridge0708:30335490
bridge0723:30353136
cmake_vspar411:30581797
vsaa593:30376534
pythonvs932:30410667
cppdebug:30492333
vsclangdc:30486549
c4g48928:30535728
dsvsc012:30540252
azure-dev_surveyone:30548225
pyindex848:30577860
nodejswelcome1:30587005
2e4cg342:30602488
gswce1:30612156
iaj6b796:30613358
dbltrim-noruby:30604474
89544117:30613380
fim-prod:30623723
ejf25101:30620729
I'm having this same problem ... I'm using VS Code 1.74.0-insider. I'm using Ubuntu, so I don't think this is OS related.
Same here
Same here
saaame
Same here.
this. same here
Queuing myself into the list of people experiencing this issue 👀
Same here.
- VS Code 1.74.0
- Ubuntu 22.04
- vscodevim 1.24.3
Same here.
vscodevim v1.24.3 Version: 1.74.1 (user setup) Commit: 1ad8d514439d5077d2b0b7ee64d2ce82a9308e5a Date: 2022-12-14T10:30:51.966Z Electron: 19.1.8 Chromium: 102.0.5005.167 Node.js: 16.14.2 V8: 10.2.154.15-electron.0 OS: Windows_NT x64 10.0.19045 Sandboxed: Yes
I'm seeing the same here on Ubuntu.
lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 22.04.1 LTS Release: 22.04 Codename: jammy
vscodevim v1.24.3 Version: 1.74.1 Commit: 1ad8d514439d5077d2b0b7ee64d2ce82a9308e5a Date: 2022-12-14T10:35:03.979Z Electron: 19.1.8 Chromium: 102.0.5005.167 Node.js: 16.14.2 V8: 10.2.154.15-electron.0 OS: Linux x64 5.15.0-56-generic Sandboxed: Yes
Same issue... tried
{
"before": ["u"],
"commands": ["undo"]
},
{
"before": ["r"],
"commands": ["redo"]
}
with no luck
Same here
Versión: 1.74.2 Commit: e8a3071ea4344d9d48ef8a4df2c097372b0c5161 Fecha: 2022-12-20T10:32:21.587Z Electrón: 19.1.8 Chromium: 102.0.5005.167 Node.js: 16.14.2 V8: 10.2.154.15-electron.0 OS: Darwin arm64 22.2.0 En espacio aislado: No
Same here.
Same here.
I'm a bit confused... iab<Esc>u should undo the entire insertion ("ab", not just "a"), which is what I'm seeing, at least on VS Code 1.74.2.
If anyone is still experiencing this, please post settings.
I'm a bit confused...
iab<Esc>ushould undo the entire insertion ("ab", not just "a"), which is what I'm seeing, at least on VS Code 1.74.2.If anyone is still experiencing this, please post settings.
I don't think this is the case being described. The issue seems to appear if you save the file.
o1<Esc>:w<Enter>o2<Esc>uu will only undo the "2".
It seems this issue is fixed now, at least in my VS Code 1.74.2.
Version: 1.74.2 (Universal) Commit: e8a3071ea4344d9d48ef8a4df2c097372b0c5161 Date: 2022-12-20T10:26:09.430Z Electron: 19.1.8 Chromium: 102.0.5005.167 Node.js: 16.14.2 V8: 10.2.154.15-electron.0 OS: Darwin arm64 22.3.0 Sandboxed: No
It seems this issue is fixed now, at least in my VS Code 1.74.2.
Version: 1.74.2 (Universal) Commit: e8a3071ea4344d9d48ef8a4df2c097372b0c5161 Date: 2022-12-20T10:26:09.430Z Electron: 19.1.8 Chromium: 102.0.5005.167 Node.js: 16.14.2 V8: 10.2.154.15-electron.0 OS: Darwin arm64 22.3.0 Sandboxed: No
@marchbox are you able to undo changes with "u" after saving a file? I can still reproduce that issue with 1.74.2. which may be related to this. The last version where that worked for me is 1.72.2, see #8188.
It seems this issue is fixed now, at least in my VS Code 1.74.2.
It still doesn't work in my VS Code 1.74.2.
@slnc @visortelle yeah I was able to undo after saving (both with :w and CMD+S)