-
Notifications
You must be signed in to change notification settings - Fork 770
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
Pylance not working in vs code interactive window #1586
Comments
Would you please provide logs and repro steps as described in the troubleshooting guide, please? |
pylance version v2021.7.5 The code is pretty much what you see in the image I attached, but the code could be anything, e.g: |
langserverlog.txt |
Things aren't working because the LS is crashing.
The logs show that one of your paths is apparently empty:
Potentially null. I think this is because you are not opening a folder (open file mode has a few known issues), but we shouldn't be crashing or adding an empty workspace path as a search path (or then try to watch it). |
I could do another log, when actually opening an repo and then going into interactive window. I am pretty sure that was what I did when I posted the problem yesterday (see original post and image). Would it be of help to have that log too? |
I think we have enough info. You should be able to work around this by using |
First the workaround works, i get the autocomplete as expeted, and then i stops, see image |
The other thing to confirm is that the interpreter that you've selected is the same one that is running the kernel. Pylance uses the interpreter that the Python extension chooses, but Jupyter uses a separate selection that isn't always synchronized. Try creating a plain python file in that folder and write the same code, and see if |
When a create a plain python file, everything works, a get autcomplete for alt. And that is my experience, I have this problem when running interactive window. |
Same issues here in Version: 1.59.0-insider (apple silicon native) |
The next version should fix various errors / bad behaviors caused by open-file mode; we weren't being too careful about handling an unrooted execution environment in a number of places (but now handle it explicitly). |
This issue has been fixed in version 2021.9.2, which we've just released. You can find the changelog here: https://github.com/microsoft/pylance-release/blob/main/CHANGELOG.md#202192-16-september-2021 |
Discussed in #1585
Originally posted by dataagile-ema July 22, 2021
Hi!
Whenever pylance detects a problem when i am in the interactive window in vs code, it just stops working. It no longer gives autocomplete (to make things worse, pylance detects problem even when there is no problem). I hope the attached image shows the problem.
I would greatly appreciate help on ths, it i really irritating. Pylance autocomplete really speads up development.
The text was updated successfully, but these errors were encountered: