Description
Environment data
- VS Code version: 1.45.1
- Extension version (available under the Extensions sidebar): 2020.5.78807
- OS and version: Windows 7
- Python version (& distribution if applicable, e.g. Anaconda): Anaconda Python 3.7
- Type of virtual environment used (N/A | venv | virtualenv | conda | ...): conda
- Relevant/affected Python packages and their versions: Everything
- Relevant/affected Python-related VS Code extensions and their versions:
- Jedi or Language Server? (i.e. what is
"python.jediEnabled"
set to; more info How to update the language server to the latest stable version #3977): false - Value of the
python.languageServer
setting: Microsoft
Expected behaviour
I think registry access is just required for listing the installed python environments.
If access to reg.exe is denied, the extension should fall back to maybe just getting the python.exe from the PATH variable instead of failing to load completely.
Actual behaviour
The extension fails to load. If I try to use any feature like the data science UI, I get the error "spawn EPERM".
Steps to reproduce:
- Use vscode-python in windows where running reg.exe gives access denied.
- The extension cannot load and most of the commands give error "spawn EPERM"
Logs
This is happening in my work environment and I can't login to Github there. I can see in the console output that there is "spawn EPERM" error in getInterpretersFromRegistry.
Also, this wouldn't have been an issue if the winreg module in nodejs worked like winreg in python. Python uses the win32 api instead of spawning reg.exe subprocess, and that works even if reg.exe is blocked. So maybe switching from winreg to something else can also be considered?