我如何求解没有名为错误的模块?
您好,我正在使用Python 3和Ros Noetic,并且我遇到了此错误
import can
ImportError: No module named can
,以前遇到了此错误,我通过Google中的非常简单的Can-Bus相关安装命令解决了它。但是我现在找不到该命令 我已经尝试了所有类似的$ sudo apt install python3-can
。 但是我根本无法修复它,
谢谢...............................
hello i'm using python 3 and ros noetic, and i got this error
import can
ImportError: No module named can
I've got this error before, and I solved it through a very simple can-bus related installation command in google. But I can't find that command now
I've tried all the like $ sudo apt install python3-can
.
but I can't fix it at all
thank you................
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
问题是,您的Python找不到该模块。
首先,尝试使用以下方式删除软件包,
然后将其重新安装,
以防您安装了几个版本的Python(例如Python2和Python3),请确保您使用
代替PIP。
接下来,您可以尝试手动搜索包装目录,以查看包装。
The problem is, that the module can't be found by your python.
first, try to remove the package with:
and re-install it with
In case you have several versions of python installed (such as python2 and python3) make sure, you use
instead of pip.
Next you can try to manually search your package directories for the package, if it is even there.
尝试使用git克隆库并运行设置。Py安装,对我有用。
Try cloning the library with git and running the setup.py installation, worked for me.