Pipenv environment is not activated using pipenv shell
See original GitHub issueEnvironment data
- VS Code version: 1.45.1
- Extension version (available under the Extensions sidebar): 2020.5.80290
- OS and version: Windows 10, build 18363
- Python version (& distribution if applicable, e.g. Anaconda): 3.7.7, python.org
- Type of virtual environment used (N/A | venv | virtualenv | conda | …): pipenv
- Value of the
python.languageServer
setting: Microsoft
Expected behaviour
When opening a new git bash terminal, the pipenv environment is properly activated.
Actual behaviour
jakub@LAPTOP-6R3A0N4R MINGW64 /d/Fiverr_28 (master)
$ source C:/Users/jakub/.virtualenvs/Fiverr_28-MrJNCoYT/Scripts/activate
(Fiverr_28)
which does not activate the environment properly in GitBash
Steps to reproduce:
- Set the default integrated terminal to GitBash
- Create new Pipenv environment
- Set the project interpreter to the adequate venv
- Open a new integrated terminal
What I suggest
Pipenv provides a really useful layer of abstraction and one of it’s features is the pipenv shell
command, which is not being used in this case. Using this command instead of directly running the activation script would resolve this issue.
The issue #2559 would also be resolved by using pipenv shell
instead of directly activating the venv.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:2
- Comments:10
Top Results From Across the Web
Pipenv environment is not activated using pipenv shell #16988
Using this command instead of directly running the activation script would resolve this issue.
Read more >pipenv shell, does not activate the virtual environment
Try doing this: pip uninstall pipenv. this will uninstall existing pipenv after doing that re-install pipenv by doing this:
Read more >Frequently Encountered Pipenv Problems - Read the Docs
This is usually a result of mixing Pipenv with system packages. We strongly recommend installing Pipenv in an isolated environment. Uninstall all existing ......
Read more >How to manage your python virtualenvs with Pipenv - Medium
Activate the environment. To open a shell with the already created virtualenv pipenv shell. You would see something like below:
Read more >Configure a Pipenv environment | IntelliJ IDEA Documentation
At any time you can alter the specified path to the pipenv executable in the project settings. In the Settings ...
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
Perhaps https://github.com/microsoft/vscode-python/issues/8870 could also help as a workaround. Please upvote, helps bump the priority.
Should be fixed along with https://github.com/microsoft/vscode-python/issues/12020, but let’s keep this open until then.