I get 'ImportError: No module named web' despite the fact that it is installed

随声附和 提交于 2019-12-04 20:38:17
Philip Tzou

According to the output of your sys.path, you are probably using OSX Python to run your script (app.py) but using Homebrew Python to execute PIP command. The solution is pretty simple:

brew link --overwrite python

This will change your default Python to Homebrew one. After executing this command, you can verify you are using Homebrew Python by typing this command:

which -a python

The result should be like this (sequence matters):

/usr/local/bin/python
/usr/bin/python

Else you can try using python -m pip install lpthw.web in command prompt, this worked for me.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!