我已通过pip
安装了virtualenvwrapper
和pip
。我在.bashrc
# virutalenvwrapper
export VIRTUALENVWRAPPER_VIRTUALENV=/usr/local/bin/virtualenv
source /usr/local/bin/virtualenvwrapper.sh
我在收到.bash_profile
时收到错误:
$ source ~/.bash_profile
Traceback (most recent call last):
File "<string>", line 1, in <module>
ImportError: No module named virtualenvwrapper.hook_loader
virtualenvwrapper.sh: There was a problem running the initialization hooks.
If Python could not import the module virtualenvwrapper.hook_loader,
check that virtualenv has been installed for
VIRTUALENVWRAPPER_PYTHON=/Library/Frameworks/Python.framework/Versions/2.7/bin/python and that PATH is
set properly.
这是什么错误?我见过很多人有同样的错误,我已经尝试了列出的建议,似乎没有人跟我合作。
我正在运行OS X Mountain Lion和Python 2.7。
答案 0 :(得分:0)
运行which virtualenv
以查看virtualenv的路径