-
Notifications
You must be signed in to change notification settings - Fork 765
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
"Received redundant open text document command" when working off mapped network drive #5326
Comments
I get something different. Attempting to do a rename has this effect:
My guess is that we're turning the URI for the rename into the real path instead of using the original URI. |
You may need to add "tsclient" to the Also, rolling back to pylance v2023.10.50 does solve this issue for me. |
That does get me farther, the rename occurs but we open a new file (instead of just renaming inside the current file). Well because the URI we return for the rename has the real path instead of the mapped one. |
I start getting these then:
At no point does it stop working though. It's just returning the wrong URIs. Hover still works on the original file, goto def still works. etc. |
I can sometimes reproduce the 'opening a new file' behavior you're seeing. If you close that new file and go back to the original one that is still open, I lose variable coloring and type hints and pylance doesn't work. "Go to definition" opens up a new file again. in So definitely something related to not knowing the real path and mapped path are the same files. |
This issue has been fixed in prerelease version 2023.12.104, which we've just released. You can find the changelog here: CHANGELOG.md |
Environment data
Repro Steps
In windows, let's say I have \\server\storage mapped to z:\
Fairly regularly when working on a file Pylance will crash with this error:
And then pylance no longer functions on that file until you close and reopen it within VS Code.
An easy way to trigger this is to hit f2 or click "Rename symbol", so this might be related to #5030. However, I get frequent crashes when working on a python file even without renaming a symbol specifically.
Logs
Renaming a symbol in z:\test\test.py results in the following error:
If you keep typing after that:
The text was updated successfully, but these errors were encountered: