Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

save failure #14635

Closed
ylqhust opened this issue Oct 28, 2016 · 9 comments
Closed

save failure #14635

ylqhust opened this issue Oct 28, 2016 · 9 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug candidate Issue identified as probable candidate for fixing in the next release *caused-by-extension Issue identified to be caused by an extension verified Verification succeeded
Milestone

Comments

@ylqhust
Copy link

ylqhust commented Oct 28, 2016

  • VSCode Version: Code 1.6.1 (9e4e44c, 2016-10-13T15:27:10.246Z)
  • OS Version: Darwin x64 16.0.0
  • Extensions: donjayamanne.python-0.5.0, luniclynx.lex-0.1.0, ms-vscode.cpptools-0.9.2, se2dev.vscode-yacc-1.0.1, slevesque.shader-0.2.2, tht13.python-0.2.3, tushortz.python-extended-snippets-0.0.1, vscodevim.vim-0.4.0

Steps to Reproduce:
编辑一个文件并且保存后,然后去编辑别的文件,过了一会在回来看,原来的文件保存失效,文件内容是上一次的内容,这个bug很严重啊,我的电脑上已经发生了好几次了,这个不解决只能投入atom的怀抱了

@bpasero
Copy link
Member

bpasero commented Oct 28, 2016

@ylqhust can you try to provide the issue description in english?

@bpasero bpasero added the info-needed Issue requires more information from poster label Oct 28, 2016
@ylqhust
Copy link
Author

ylqhust commented Oct 31, 2016

I edit a file and save edit then I to edit another file . after sometimes ,I come back to see the first file .I find the first file's content is not I saved. this problem have happend many times

@bpasero bpasero added the bug Issue identified by VS Code Team member as probable bug label Oct 31, 2016
@jrieken jrieken assigned bpasero and unassigned jrieken Oct 31, 2016
@bpasero
Copy link
Member

bpasero commented Oct 31, 2016

@ylqhust
I wonder if this issue is being caused by an installed extension. Can you try to run VS Code without extensions? From the command line (NOT the integrated terminal in Code), execute: code --disable-extensions and try your steps again to see if it reproduces. If you see it is an issue with the extension, please file it against the extension repository itself.

@bpasero bpasero added this to the Backlog milestone Oct 31, 2016
@jrieken jrieken self-assigned this Oct 31, 2016
@jrieken
Copy link
Member

jrieken commented Oct 31, 2016

Taking this back. @ylqhust As mentioned earlier, please try without extension.

I have added telemetry about saving participant times, most interesting is how long format on save takes (upper bound 750ms) and how long the on-will-save-event takes (upper bound 1500ms).

Turns that there are extensions host that are more or less dead. Looking at the data for 'format on save' is happy (since we enforce the timeout in the main process). However, the 'will save event' is dispatched and monitored on the extension host, meaning a dead/heavy loaded extension host might run its event listeners timely but it takes a long before that happens. During the last day we have participated in more than 10000 saves and some cases (~450) it took longer that 1500ms.

@jrieken jrieken added *caused-by-extension Issue identified to be caused by an extension and removed info-needed Issue requires more information from poster labels Oct 31, 2016
@jrieken
Copy link
Member

jrieken commented Oct 31, 2016

I will put another defence mechanism in place that recovers from a dead extension host

@bpasero
Copy link
Member

bpasero commented Nov 2, 2016

Verified that if I make the extension host not reply in 1750ms the save proceeds after at least 1750ms.

The save participant on the extension is not canceled so there is still a chance that it eventually triggers (not sure if this is a problem @jrieken).

@bpasero bpasero added the verified Verification succeeded label Nov 2, 2016
@jrieken
Copy link
Member

jrieken commented Nov 2, 2016

Shouldn't be a problem because the extension host cancels itself after 1500ms - the additional check is there to protect from a dead/unresponsive extension host. Even when the operation gets through in time at worst it will trigger another dirty/save cycle

@alecmce
Copy link

alecmce commented May 9, 2017

I have started to have this problem yesterday. I reinstalled Version 1.12.1 (1.12.1) and can reproduce. I open a file and edit it, but VS Code does not recognize it as edited. When I save nothing happens. VSCode remembers my edits but if I view the file from another editor, the edits have not been saved.

@bpasero
Copy link
Member

bpasero commented May 9, 2017

@alecmce I suggest to open a new issue on it.

@vscodebot vscodebot bot locked and limited conversation to collaborators Nov 18, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug candidate Issue identified as probable candidate for fixing in the next release *caused-by-extension Issue identified to be caused by an extension verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

4 participants