Reputation: 3897
I have python 2.7.9
installed system wide.
Then I've installed virtualenvwrapper
on that python version.
After that, I've installed pyenv
, then I've installed python 3.3.1
pyenv install 3.3.1
Hashed the shims of that version, exported $PATH
variables of pyenv
into my bash_profile
file (I'm on Debian Wheezy).
Then, I need to run that python version 3.3.1
to work on a Django project.
BUT, I also need virtualenvwrapper installed on THAT python version, which is 3.3.1
not 2.7.9
But when 3.3.1
activated, I try to run pip install virtualenvwrapper
to install it on Python3, but it keeps looking for the system wide version so I cannot install it, this is the entire traceback:
user@debian:~/python_examples/orthosie$ pyenv local
3.3.1
user@debian:~/python_examples/orthosie$ pip install virtualenvwrapper
You are using pip version 6.0.6, however version 7.1.2 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Requirement already satisfied (use --upgrade to upgrade): virtualenvwrapper in /usr/lib/python2.7/dist-packages
Requirement already satisfied (use --upgrade to upgrade): virtualenv in /usr/local/lib/python2.7/dist-packages (from virtualenvwrapper)
user@debian:~/python_examples/orthosie$
What am I doing wrong here? Maybe I can run it from system wide virtualenvwrapper
?
Thanks in advance!
Upvotes: 0
Views: 94
Reputation: 2843
I think you have to set the python version globaly using pip, since it is invoked in one of the /bin
dirs where you haven't changed your python version.
You can see where pip lies on your system using $ which pip
To do so use $ pyenv global 3.3.1
When using virtualenv you can specify which version you want to use in combination with pyenv via the command:
$ virtenv -p /path/to/pyenv/versions/3.3.1/python
to ensure that you will get the right version - alternativly you can use the pyenv wrapper for virtualenv
Upvotes: 1