Repository navigation
Closed
Labels
area-terminalbugIssue identified by VS Code Team member as probable bugIssue identified by VS Code Team member as probable bugneeds proposalNeed to make some design decisionsNeed to make some design decisionsverifiedVerification succeededVerification succeeded
Milestone
Description
Environment data
- VS Code version: 1.43.0
- Extension version (available under the Extensions sidebar): 2020.2.64397
- OS and version: Windows 10
- Python version (& distribution if applicable, e.g. Anaconda): 3.7.6
- Type of virtual environment used (N/A | venv | virtualenv | conda | ...): pipenv
- Relevant/affected Python packages and their versions: pipenv 2018.11.26
- Relevant/affected Python-related VS Code extensions and their versions: N/A
- 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): Jedi - Value of the
python.languageServersetting: Microsoft
Expected behaviour
When opening a terminal in a project with a pipenv environment selected, the environment should be activated using pipenv shell. This seems to be indicated as the expected behavior by the resolution of issue #2855.
Actual behaviour
The pipenv environment is activated using <pipenv dir>/Scripts/activate.ps1. This causes the .env file to not be loaded.
Steps to reproduce:
[NOTE: Self-contained, minimal reproducing code samples are extremely helpful and will expedite addressing your issue]
- Create a new directory.
- In a terminal, navigate to the new directory and create a pipenv environment using
pipenv shell. - Open VS Code on the new directory.
- Create a new python file in the directory, so the Python extension is loaded.
- Ensure that the correct pipenv environment is selected.
- Open a new terminal in VS Code.
- Observe that the environment is activated using
<pipenv dir>/Scripts/activate.ps1and notpipenv shell.
Metadata
Metadata
Assignees
Labels
area-terminalbugIssue identified by VS Code Team member as probable bugIssue identified by VS Code Team member as probable bugneeds proposalNeed to make some design decisionsNeed to make some design decisionsverifiedVerification succeededVerification succeeded
Activity
bherbruck commentedon Mar 17, 2020
I am having the same issue in Windows with venv. None of my venvs are activating or being recognized by vscode. Maybe due to a powershell update I got today.
mixja commentedon Mar 28, 2020
This issue also applies on MacOS and is very annoying.
There seems be a history of this feature being implemented but then being reverted.
DonJayamanne commentedon Mar 29, 2020
Karthik Nadig (@karthiknadig) Luciana Abud (@luabud)
Fyi #4394, #4203
karrtikr commentedon Oct 22, 2021
Handle #4203 if and when bringing
pipenv shellback.karrtikr commentedon Oct 22, 2021
Closing in favor of #16988