Trouble detecting environments
See original GitHub issueEnvironment data
- VS Code version: 1.51.1
- Extension version (available under the Extensions sidebar): v2020.11.371526539
- OS and version: Windows 10
- Python version (& distribution if applicable, e.g. Anaconda): Python 3.8
- Type of virtual environment used (N/A | venv | virtualenv | conda | …): venv
- Value of the
python.languageServer
setting: Pylance
Expected behaviour
The extension finds all interpreters listed under the venv Path variable.
Actual behaviour
The interpreter finds none of them (except those already in cache?)
Steps to reproduce:
Note too sure. For a while the select interpreter worked flawlessly but not anymore.
Logs
Error 2020-12-08 09:00:48: Failed to get interpreter information for 'C:\Users\xxx\venvs\ptf7\Scripts\python.exe' [Error: Command failed: "C:\\Users\xxx\venvs\ptf7\Scripts\python.exe" "c:\Users\xxx\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py" "c:\Users\xxx\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\interpreterInfo.py"
at ChildProcess.exithandler (child_process.js:304:12)
at ChildProcess.emit (events.js:223:5)
at maybeClose (internal/child_process.js:1021:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:283:5)] {
killed: true,
code: null,
signal: 'SIGTERM',
cmd: '"C:\\\\Users\\xxx\\venvs\\ptf7\\Scripts\\python.exe" "c:\\Users\\xxx\\.vscode\\extensions\\ms-python.python-2020.11.371526539\\pythonFiles\\pyvsc-run-isolated.py" "c:\\Users\\xxx\\.vscode\\extensions\\ms-python.python-2020.11.371526539\\pythonFiles\\interpreterInfo.py"'
However the above command when pasted in a new terminal window works flawlessly:
{"versionInfo": [3, 7, 5, "final", 0], "sysPrefix": "C:\\Users\\xxx\\venvs\\ptf7", "sysVersion": "3.7.5 (tags/v3.7.5:5c02a39a0b, Oct 15 2019, 00:11:34) [MSC v.1916 64 bit (AMD64)]", "is64Bit": true}
Issue Analytics
- State:
- Created 3 years ago
- Reactions:2
- Comments:9
Top Results From Across the Web
Detecting Changes and Avoiding Catastrophic Forgetting in ...
The ability of an agent to detect changes in an environment is key to successful adaptation. This ability involves at least two phases:...
Read more >Identifying problems in your cloud environment - IBM
Troubleshooting is a systematic approach to solving a problem. The goal is to determine why something does not work as expected and how...
Read more >Improving environment detection by behavior association for ...
Behavioral contexts cover both human activities and vehicle motions. The performance of behavior recognition in this paper is improved by feature selection and ......
Read more >Detecting Environment-Sensitive Malware - UCSB Seclab
Abstract. The execution of malware in an instrumented sandbox is a widespread approach for the analysis of malicious code, largely because it.
Read more >Challenges to detect SARS-CoV-2 on environmental media ...
An analysis of several studies on the detection of SARS-CoV-2 on wastewater shows that the concentration methods used to trap the virus are...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hello Python extension team, unfortunately I keep encountering this problem. It’s very erratic. Sometimes it only lists some virtual environments, sometimes (but rarely and I can’t figure under which circumstances) all of them are correctly listed, and sometimes, only one interpreter is available.
Sounds good! Feel free to subscribe to #12020 to get notified when the new interpreter discovery logic becomes available (on an opt-in basis as first) 👍