Forums

virtualenv error on web tab

Hi

Im getting the following warning/error in my we tab

"This virtualenv seems to have the wrong Python version (2.7 instead of 3.5)"

Im definately running Python 3.5.2 (default, Jul 17 2016, 00:00:00) in the virtualenv

Its still all functioning just a little annoying and just wanted to make you guys aware

thanks Chris

Is it possible you somehow have both versions of python inside the virtualenv?

I created the virtualenv by mkvirtualenv myvirtualenv --python=/usr/bin/python3.5

Which Python shows only one version

Is there another way to check for other versions?

try "which python2" and also check the contents of your virtualenv folder with a

ls ~/.virtualenvs/my-virtualenv-name/lib

?

There is indeed a python2 version running which is really odd and I can't figure out how it got there!?

/home/pythonwedge/.virtualenvs/golfersinsight/bin/python2

I ran through the same sequence of creating a venv with 3.5 python and installing my prod requirements and then it wasn't there after, which python2 produces:

/usr/bin/python2

I'm a bit confused and need to go through the full deployment process and see when the change to the venv happens

definitely sounds like you had mistakenly installed a python2 version into your virtualenv previously. Your new virtualenv works with the webapp config now right?

Yes it would seemingly be human error in my initial creation my apologies for the inconvenience

No problem, glad you worked it out!