python3报错ModuleNotFoundError: No module named 'Queue'
2021-04-22 15:39 Tanwheey 阅读(2023) 评论(0) 编辑 收藏 举报Traceback (most recent call last):
File "test.py", line 4, in <module>
import Queue
ModuleNotFoundError: No module named 'Queue'
Process finished with exit code 1
安装包:% pip install Queue
ERROR: Could not find a version that satisfies the requirement Queue
ERROR: No matching distribution found for Queue
通过pip search Queue 确实没发现Queue模块。按照报错信息进行网络搜索,发现是因为python2.X 和python3.X 对于queue模块的写法不同。python2.X必须是Queue, 而在python3.X 中,就修改成queue了。
坑啊~~