猿问

Python - 导入错误:尽管 pip 说“要求已经满足”,但没有名为“pymongo”的模块

正如标题清楚地描述的那样,尽管我已经通过建议的方式(执行命令python -m pip install pymongo)成功安装了 PyMongo,但ImportError: No module named 'pymongo'在我尝试执行导入PyMongo.


Python 版本: 3.7.0


PyMongo版本:(3.7.1表示最佳匹配)


ps (1) 操作系统为 Windows 10。


(2) 类似问题的答案无效。


编辑:这是命令的输出python -m easy_install pymongo:


Searching for pymongo

Best match: pymongo 3.7.1

Processing pymongo-3.7.1-py3.7-win-amd64.egg

pymongo 3.7.1 is already the active version in easy-install.pth


Using c:\users\talha\appdata\local\programs\python\python37\lib\site-packages\pymongo-3.7.1-py3.7-win-amd64.egg

Processing dependencies for pymongo

Finished processing dependencies for pymongo

命令的输出python -m pip install pymongo:


Requirement already satisfied: pymongo in c:\users\talha\appdata\local\programs\python\python37\lib\site-packages\pymongo-3.7.1-py3.7-win-amd64.egg (3.7.1)

我执行的命令是通过我的 Python 脚本模拟 Android 设备,该脚本同时使用MonkeyRunner和PyMongo模块:


monkeyrunner.bat C:\Users\talha\Documents\PyCharmProjects\MonkeyRunner\test.py


红颜莎娜
浏览 257回答 2
2回答
随时随地看视频慕课网APP

相关分类

Python
我要回答