You want to install/test a library for Python but you don’t want it to interfere with the rest of the system.
You want different installation of Python and sets of libraries at the same time on your system. You also want the ability to switch from one to the other.
You are a robot (or a mathematical statement) and you have started enumerating all the possible things that you can do with your computer. Present one of those.
All these problems have a common solution.
- Install virtualenv using your package manager
You can create more than one virtual environment by choosing different directories.
Now, you use the “special environment” that is described in virt1 dir. It may contain a different version of Python, libraries that do not exist system-wide etc…
Any installation that you do at these point using tools such as pip, easy_install etc affects only this special environment.
pip install requests