Description
openedon Mar 26, 2018
This seems to have stopped working in a recent version of either VS Code or the Python extension. I believe it worked about 1 month ago.
Environment data
- VS Code version: 1.21.1
- Extension version (available under the Extensions sidebar): 2018.2.1 (09 Mar 2018)
- OS and version: MacOS High Sierra 10.13.3
- Python version (& distribution if applicable, e.g. Anaconda): 2.7 (system) / 3.6 (Homebrew)
- Type of virtual environment used (N/A | venv | virtualenv | conda | ...): venv
- Relevant/affected Python packages and their versions: N/A
Actual behavior
Python: Select Interpreter menu only shows 3 interpreters - /usr/bin/python2.7, /usr/local/bin/python3, /User/kristofferb/.venv/flask-rest-test/bin/python
The flask-rest-test entry is loaded (title is "Python 3.6.4 (venv)"), however this resides under another .venv folder I've previously used (not the one specified in python.venvPath
). Why this works, is not clear to me, it might be because I've specified this manually in another project.
Expected behavior
All interpreters under the specified python.venvPath
is made available, not just system (and one which is recently used)
Steps to reproduce:
python -m venv ~/.venv2/test_vscode_venv
mkdir test_vscode_venv; echo "import this" > test_vscode_venv/test.py; code test_vscode_venv
- change User Settings to
{"python.venvPath": "~/.venv2/"}
- open Python: Select Interpreter menu - the interpreteres shown are those under Actual behavior
Logs
Output for Python
in the Output
panel (View
→Output
, change the drop-down the upper-right of the Output
panel to Python
)
Linter 'pylint' is not installed. Please install it or select another linter".
Error: Module 'pylint' not installed.
Output from Console
under the Developer Tools
panel (toggle Developer Tools on under Help
)
console.ts:136 [Extension Host] Python Extension: Linter 'pylint' is not installed. Please install it or select another linter". Error: Module 'pylint' not installed.
at PythonExecutionService.<anonymous> (/Users/kristofferb/.vscode/extensions/ms-python.python-2018.2.1/out/client/common/process/pythonProcess.js:92:27)
at Generator.next (<anonymous>)
at fulfilled (/Users/kristofferb/.vscode/extensions/ms-python.python-2018.2.1/out/client/common/process/pythonProcess.js:12:58)
at <anonymous>
[...]
console.ts:136 [Extension Host] Python Extension: Linter 'pylint' is not installed. Please install it or select another linter". Error: Module 'pylint' not installed.
at PythonExecutionService.<anonymous> (/Users/kristofferb/.vscode/extensions/ms-python.python-2018.2.1/out/client/common/process/pythonProcess.js:92:27)
at Generator.next (<anonymous>)
at fulfilled (/Users/kristofferb/.vscode/extensions/ms-python.python-2018.2.1/out/client/common/process/pythonProcess.js:12:58)
at <anonymous>
[...]