VirtualEnv
Way to build isolated Python Deployment Environment-s.
Now obsolete, replaced with venv? But even that is semi-obsolete? Stefano Borini: Current Status of Python Packaging - 2019: I assume you are a programmer and wants to start developing a python package:
- Create your development environment with Poetry, specifying the direct dependencies of your project with a strict version. This way you ensure your development (and testing) environment is always reproducible.
- Create a pyproject.toml and use poetry as a backend to create your source and binary distributions.
- Now it’s time to specify your abstract package dependencies. Specify them with a minimum version that you know your package can work with. This way you ensure you don’t create needless version conflicts with other packages.
Or maybe it's still not that simple. https://www.reddit.com/r/learnpython/comments/vb0bag/how_to_choose_between_venv_virtualenv_asdf_poetry/ pyenv, poetry, asdf....
2024: going to following this recipe: (2023-03-27) BiteCode on Python installation and packaging esp on Mac
http://www.arthurkoziel.com/2008/10/22/working-virtualenv/
With pip and Django http://www.saltycrane.com/blog/2009/05/notes-using-pip-and-virtualenv-django/
Aug'2010: I have it in /documents/djcode/pinax-env/
- for Pyramid and WebPy have one in /documents/djcode/st/
- cd into there
- type
source bin/activate
Feb'2014: changing a virtualenv to use python 2.7 instead of 2.6.
$ which python
/Users/billseitz/Documents/djcode/st/bin/python
$ which python2.7
/Library/Frameworks/Python.framework/Versions/2.7/bin/python2.7
$ virtualenv -p /Library/Frameworks/Python.framework/Versions/2.7/bin/python2.7 st (<path/to/new/virtualenv/>)
$ cd st
$ source/bin activate
$ python
> python2.7 - yay!
$ python code.py
> No module named web - boo!
$ sudo pip install --upgrade web.py
> (can now launch code.py - and get good page from browser)
$ pip install --upgrade selenium
Sept'2017: point-upgrading python v2.7 - see OpenSSL page
Edited: | Tweet this! | Search Twitter for discussion