microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
162.74k stars 28.72k forks source link

Ctrl+Z (Undo) operation BUG after saving the file #111487

Closed aloncGithub closed 3 years ago

aloncGithub commented 3 years ago

Issue Type: Bug

Save the file after normal Ctrl+ S. CTRL+Z (undo). Press the keyboard twice for each undo. In addition, CTRL+Y (restore) is invalid when saving the file and not exiting vscode

VS Code version: Code 1.51.1 (e5a624b788d92b8d34d1392e4c4d9789406efe8f, 2020-11-10T23:34:32.027Z) OS version: Windows_NT x64 10.0.18363

System Info |Item|Value| |---|---| |CPUs|Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz (12 x 2208)| |GPU Status|2d_canvas: enabled
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
opengl: enabled_on
protected_video_decode: unavailable_off
rasterization: enabled
skia_renderer: disabled_off_ok
video_decode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled| |Load (avg)|undefined| |Memory (System)|15.87GB (8.08GB free)| |Process Argv|--crash-reporter-id 23eeff89-d5b1-472b-9be8-a69c954cf3ac| |Screen Reader|no| |VM|0%|
Extensions (30) Extension|Author (truncated)|Version ---|---|--- lua-debug|act|1.29.1 vscode-color|ans|0.4.5 vscode-nextgenas|bow|1.4.0 vscode-swf-debug|bow|1.2.2 path-intellisense|chr|2.3.0 cocos-creator|Chu|0.0.1 cocos-debug|Chu|0.0.1 bracket-pair-colorizer-2|Coe|0.2.0 gitlens|eam|11.0.6 EditorConfig|Edi|0.16.3 tslint|eg2|1.0.44 auto-close-tag|for|0.5.9 vscode-lua|gcc|0.1.2 google-translate|han|1.1.6 docker-linter|hen|0.5.0 luacoderassist|liw|2.3.9 vscode-quickxdev|lon|0.1.0 vscode-language-pack-zh-hans|MS-|1.51.2 python|ms-|2020.11.371526539 jupyter|ms-|2020.11.372831992 cpptools|ms-|1.1.2 debugger-for-chrome|msj|4.12.11 cocos-creator-js|nex|0.1.6 view-in-browser|qin|0.0.5 markdown-preview-enhanced|shd|0.5.13 vscode-lua|tri|0.12.4 JavaScriptSnippets|xab|1.8.0 local-history|xyz|1.8.1 luahelper|yin|0.1.39 material-theme|zhu|3.9.11
其写入剪贴板,请粘贴。
egamma commented 3 years ago

/needsMoreInfo

aloncGithub commented 3 years ago

/ needsMoreInfo step:

  1. Set up Auto Save: afterDelay
  2. Set up Auto Save Delay: 500
  3. Edit a piece of code
  4. Ctrl+Z ( Revoke ) ,It will be stuck at this time
  5. Ctrl+Y ( Restore ) , invalid
alexdima commented 3 years ago

@aloncGithub Does this reproduce when disabling all extensions? Press F1 and then choose Developer: Reload Window with Extensions Disabled

Kapture 2020-07-20 at 15 28 23

Here I have tried with your steps and could not reproduce: TO_UPLOAD

aloncGithub commented 3 years ago

This problem has been solved. Thank you very much

After testing, it was found that it was a plugin called EditorConfig for VS Code. It caused conflicts.