3

Recently my OS (Arch Linux) updated Python from 3.5.2 to 3.6, after that I had a little problem with VirtualEnvWrapper, it's solved now. I wished to try my existing virtual enviroment that was created with Python 3.5.2, but...

$ workon default_env
$ python --version
Python 3.6.0
$ deactivate
$ python --version
Python 3.6.0

Something is really wrong here, because output should be Python 3.5.2 and not Python 3.6. In or out of my virtual environment if I run this:

$ pip list

I get the same packages listed. Where are my packages installed for my virtual environment (VE)? For example, If I try run ipython from my VE I get this:

$ ipython
bash: /home/user/.envs/default_env/bin/ipython: /home/user/.envs/default_env/bin/python3.5: bad interpreter: No such file or directory

I tried with this post, but it's not useful.

Community
  • 1
  • 1
  • You can check if your using the python from you virtualenv after your `workon default_env` by doing a `whereis python`, check if it is your virtual_env. If not, recreate it ! – Alexis Tacnet Jan 15 '17 at 20:55

1 Answers1

0

Reading this post I looked into pyenv and pyenv-virtualenv, and with the help of this great tutorial, I found a tool quite similar to Ruby's RVM, I love it because it won't any problems with future updates from system. Right, there is another tool like conda, but I like more pyenv.

Community
  • 1
  • 1