我在虚拟环境中运行 python3,但是当我尝试导入新安装的包时,我收到一条ImportError: No module named ...
错误消息,尽管我在运行!env/bin/pip3 list
.
当我键入时,sys.path
我看不到任何指向我的 virtualenv 的路径:
['',
'/Library/Frameworks/Python.framework/Versions/3.5/lib/python35.zip',
'/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5',
'/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/plat-darwin',
'/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/lib-dynload',
'/Users/zurfarosa/Library/Python/3.5/lib/python/site-packages',
'/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages',
'/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/IPython/extensions',
'/Users/zurfarosa/.ipython',
'/Users/zurfarosa']
如何将我的虚拟环境添加到我的 PYTHONPATH?