How to deactivate current environment entered by `pipenv shell`?
See original GitHub issue❯ python -V
Python 2.7.10
❯ pipenv shell
Spawning environment shell (/bin/zsh).
source /Users/jeyraof/Work/fashion-keyword/.venv/bin/activate
❯ source /Users/jeyraof/Work/fashion-keyword/.venv/bin/activate
(fashion-keyword)❯ python -V
Python 3.6.0
(fashion-keyword)❯ deactivate
❯ python -V
Python 3.6.0
❯ exit
❯ python -V
Python 2.7.10
exit
command is correct way to deactivate current environment?
Issue Analytics
- State:
- Created 7 years ago
- Reactions:32
- Comments:36 (10 by maintainers)
Top Results From Across the Web
Pipenv & Virtual Environments
workon also deactivates whatever environment you are currently in, so you can quickly switch between environments. Deactivating is still the same: $ deactivate....
Read more >Python venv: How To Create, Activate, Deactivate, And Delete
Once you have finished working on your project, it's a good habit to deactivate its venv. By deactivating, you leave the virtual environment....
Read more >2 years, 7 months ago - codingforentrepreneurs.com
Yeah that's a common thing. Just close out the terminal (or type exit ) and navigate to your project again and pipenv shell...
Read more >Using Python environments in VS Code
If one is found, then no other interpreters are searched for or listed as pipenv expects to manage all aspects. The extension also...
Read more >Python Virtual Environments: A Primer
To get to this point, you began by creating a Python virtual environment named venv and then activated it in your current shell...
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
pipenv starts a new shell session with the virtualenv pathing instead of changing the pathing in the current shell session. That is why deactivate does not work. you need to exit the shell session. the
exit
command or CTRL-d will do the trick.What about adding a
pipenv exit
to “close” the environment (so it can be documented).