I\'m running Mac OS 10.6.8. and wanted to install in addition to python 2.6 also python 2.7 and use python 2.7 in a new virtualenv. I executed the following steps:
I
I had the same problem as this one and spent so much time on configuring out what was wrong. And I finally found out what was wrong.
First I looked for where virtualenvwrapper folder exists. In my case /usr/local/lib/python3.7/site-packages. Inside the folder is hook_loader.py that caused the error.
Next, I used python script.
python3
import sys;print('\n'.join(sys.path))
I couldn't find the /usr/local/lib/python3.7/site-packages directory so, at last I wrote,
export PYTHONPATH=$PYTHONPATH:/usr/local/lib/python3.7/site-packages
to .bashrc file. Done.
Meaning of PYTHON PATH
As you can see in above link, PYTHONPATH augment the default search path for modules.