vscodium: Python autocompletion doesn't work with VS Code Python extenstion (Pylance)
Describe the bug
When I am using VS Codium and have the VS Code Python and Pylance extensions installed and enabled, I don’t get any autocomplete options or suggestions and it shows No suggestions
.
As you can see I have enabled only the Python extension and it shows No suggestions
. Now when I disable I get some suggestions but they are not Python suggestions, but rather just suggesting text from other parts of the file.
But not even this works when the extension is turned on.
Please confirm that this problem is VSCodium-specific
- This bug doesn’t happen if I use Microsoft’s Visual Studio Code. It only happens in VSCodium.
Please confirm that the issue/resolution isn’t already documented
- I checked the Docs page and my issue is not mentioned there.
Desktop (please complete the following information):
- OS: Ubuntu 20.04 LTS
- Architecture x64
- Version 1.61.2
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Reactions: 1
- Comments: 21 (3 by maintainers)
Commits related to this issue
- Fix Pylance being unusable in Code-OSS See https://github.com/VSCodium/vscodium/issues/892#issuecomment-957850440 — committed to nymous/dotfiles by nymous 2 years ago
The issue is that Microsoft prevents PyLance from being used in non-official builds. A workaround is to modify the
product.json
file, and setnameLong
to"Visual Studio Code"
.Source: https://www.reddit.com/r/linux/comments/k0s8qw/comment/ggnqes7/
I’ve already tried this solution but it never worked for me. BUT it seems that the combination of 2 different changes in the
product.json
file makes the things working again!The python extension is tricky since it’s using a closed source server (pylance). I do believe that the best course of action would for some python devs to fork that extension and replace the closed source part with a new open source project.
Thank you, it worked for me too. 👍
Sorry for issue necromancy, but I found another potential solution today: Uninstall the Microsoft Python extension and install the Pyright extension instead. It’s still Microsoft, but it provides auto-completion and error checking, and works on VSCodium out of the box without modification.
@an4s911 confirmed here as well with version 1.61. It seems to me that the last working release is the 1.56
Thanks. Just like some others have mentioned, this worked for me as well. I think I will close the issue now as the issue is solved for me as well as others.
If the above mentioned solution didn’t work then try the below and it should probably fix it.
And I am closing this Issue. Thanks to everyone who helped and contributed ✌
I have the same issue on Windows 10, VsCodium 1.61.2
I originally was not getting even classes and functions in the outline so I removed Pylance, which helped with the Outline but I now have no autocompletion.
This use work fine in early versions this year but I cant tell the last working version.
@ghtmtt What does it say in the Python output terminal?
Before I change
nameLong
:After I change, it simply prints:
with no error after it.