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

Insiders crashing because file is not opened before sending commands operating on that open file #79650

Closed
sheetalkamat opened this issue Aug 22, 2019 · 2 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug verified Verification succeeded
Milestone

Comments

@sheetalkamat
Copy link
Member

  • VSCode Version:
  • OS Version:

Steps to Reproduce:

Issue transfer from microsoft/TypeScript#32827

From the server log the command getApplicableRefactors is called before opening the file.

Does this issue occur when all extensions are disabled?: Yes/No

@mjbvz mjbvz modified the milestones: September 2019, August 2019 Aug 24, 2019
@mjbvz mjbvz added the bug Issue identified by VS Code Team member as probable bug label Aug 24, 2019
@mjbvz mjbvz closed this as completed in e3b9b8e Aug 24, 2019
@wclr
Copy link

wclr commented Aug 24, 2019

I disabled all the extensions (left only some important to me and ui related), and it seems to work ok for a couple of days.

@mjbvz
Copy link
Contributor

mjbvz commented Aug 28, 2019

Marking this as verified as I don't have verification steps. I believe it was the result a race condition similar to the following:

  1. We request a list of refactorings from TS Server
  2. These are shown to the user
  3. While the user is selecting a refactoring, something causes the current file to be closed on the TS Server
  4. The user then accepts a refactoring
  5. While resolving the refactoring, we send another request to the TS Server using the old file that has since been closed. This is where the crash happened

My fix was to check again if the file is opened in step 5

@mjbvz mjbvz added the verified Verification succeeded label Aug 28, 2019
@vscodebot vscodebot bot locked and limited conversation to collaborators Oct 8, 2019
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 verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

3 participants