livewires MacOS 中“初学者”的模块错误 - 初学者

时间:2021-05-31 13:54:33

标签: python module modulenotfounderror livewires

我是 Python 的初学者,正在学习一本名为“面向绝对初学者的 Python 编程”的书,但在导入 livewires 时遇到了问题。

当我写 from livewires import games 时,它弹出错误:

line 1, in <module>
from livewires import games
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/livewires/__init__.py", line 32, in <module>
from beginners import *
ModuleNotFoundError: No module named 'beginners'

我不知道如何处理这个问题,因为我已经研究过这个问题,而且我还没有提出解决方案。

我安装livewires的方式(我已经安装了pygame)

pip install livewires

pip install superwires

1 个答案:

答案 0 :(得分:0)

似乎 LiveWires 只支持 Python 2。您可以使用 SuperWires 代替 LiveWires:

pip3 install superwires
from superwires import games  # Just replace `livewires` with `superwires`
参考资料
相关问题