0

I'm setting up a new machine (OSX 10.12.6) and trying to get my python environment setup. I have installed both 2 and 3 with brew. The solutions described in other questions don't seem to help.

.zshrc looks like this:

export WORKON_HOME=$HOME/.virtualenvs
export PROJECT_HOME=$HOME/projects
export VIRTUALENVWRAPPER_VIRTUALENV=/usr/local/bin/virtualenv
export VIRTUALENVWRAPPER_VIRTUALENV_ARGS='--no-site-packages'

source /usr/local/bin/virtualenvwrapper.sh

Error I'm getting when I open a new shell:

/usr/bin/python: No module named virtualenvwrapper
virtualenvwrapper.sh: There was a problem running the initialization hooks.

If Python could not import the module virtualenvwrapper.hook_loader,
check that virtualenvwrapper has been installed for
VIRTUALENVWRAPPER_PYTHON=/usr/bin/python and that PATH is
set properly.

The weird thing is that everything works fine - I can use mkvirtualenv just fine. But I don't want the error message and I don't get what is going on with my path? Please help!

I installed virtualenv and wrapper with pip and pip3

pip freeze:

pbr==3.1.1
six==1.10.0
stevedore==1.26.0
virtualenv==15.1.0
virtualenv-clone==0.2.6
virtualenvwrapper==4.8.1

$PATH:

/usr/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
Bill
  • 169
  • 1
  • 3
  • 15
  • I answered a similar question just 2 hours ago: [How to check that virtualenvwrapper has been installed for VIRTUALENVWRAPPER_PYTHON=/usr/bin/python etc](https://stackoverflow.com/questions/46105511/how-to-check-that-virtualenvwrapper-has-been-installed-for-virtualenvwrapper-pyt/46106073#46106073) – David Jenkins Sep 08 '17 at 00:45
  • I definitely tried that, but still get an error, I guess I don't get how to install wrapper for that version of python? Don't my pip commands do it? – Bill Sep 08 '17 at 01:34
  • Also, it's a bit different on OSX. – Bill Sep 08 '17 at 01:35
  • Possible duplicate of [How to check that virtualenvwrapper has been installed for VIRTUALENVWRAPPER\_PYTHON=/usr/bin/python etc](https://stackoverflow.com/questions/46105511/how-to-check-that-virtualenvwrapper-has-been-installed-for-virtualenvwrapper-pyt) – bfontaine Sep 08 '17 at 09:07
  • Possible duplicate of [How to definitely install virtualenvwrapper with Python3.5 on Mac OS Sierra?](https://stackoverflow.com/questions/40732423/how-to-definitely-install-virtualenvwrapper-with-python3-5-on-mac-os-sierra) – phd Sep 08 '17 at 19:50

0 Answers0