小鱼 ROS 2 新书上线!点击链接查看, 新书配套视频点击链接查看。
提问前必看的发帖注意事项—— 提问前必看!不符合要求的问题拒绝回答!!
社区使用指南—如何添加标签修改密码
-
我在跑小乌龟程序的时候,学习网上教程想看看节点,输入了rosrun rqt_graph rqt_graph,之后就报错了,具体代码如下,请大佬们给萌新指导一下。
rosrun rqt_graph rqt_graph
PluginManager._discover() force discovery of plugins
RospkgPluginProvider._find_plugins() crawling for plugins of type 'qt_gui'
Could not import "pyside" bindings of qt_gui_cpp library - so C++ plugins will not be available:
Traceback (most recent call last):
File "/opt/ros/melodic/lib/python2.7/dist-packages/qt_gui_cpp/cpp_binding_helper.py", line 39, in <module>
from . import libqt_gui_cpp_shiboken
ImportError: cannot import name 'libqt_gui_cpp_shiboken'RospkgPluginProvider._find_plugins() crawling for plugins of type 'rqt_gui'
QtBindingHelper using pyside
PerspectiveManager.switch_perspective() switching to perspective "@rqt_graph__RosGraph"
MainWindow.restore_settings()
PluginManager.restore_settings_without_plugins()
MainWindow.restore_state()
PluginManager.load_plugin(rqt_graph/RosGraph, 0)
MainWindow.save_setup()
RosPyPluginProvider._init_node() initialize ROS node "rqt_gui_py_node_2480"
RosPluginProvider.load(rqt_graph/RosGraph) exception raised in builtin.import(rqt_graph.ros_graph, [RosGraph]):
Traceback (most recent call last):
File "/opt/ros/melodic/lib/python2.7/dist-packages/rqt_gui/ros_plugin_provider.py", line 80, in load
attributes['module_name'], fromlist=[attributes['class_from_class_type']], level=0)
File "/home/fzz/.local/lib/python3.6/site-packages/shiboken2/files.dir/shibokensupport/feature.py", line 142, in _import
return original_import(name, *args, **kwargs)
File "/opt/ros/melodic/lib/python2.7/dist-packages/rqt_graph/ros_graph.py", line 45, in <module>
from qt_dotgraph.dot_to_qt import DotToQtGenerator
File "/home/fzz/.local/lib/python3.6/site-packages/shiboken2/files.dir/shibokensupport/feature.py", line 142, in _import
return original_import(name, *args, **kwargs)
File "/opt/ros/melodic/lib/python2.7/dist-packages/qt_dotgraph/dot_to_qt.py", line 35, in <module>
import pydot
File "/home/fzz/.local/lib/python3.6/site-packages/shiboken2/files.dir/shibokensupport/feature.py", line 142, in _import
return original_import(name, *args, **kwargs)
ModuleNotFoundError: No module named 'pydot'PluginManager._load_plugin_restore()
PluginManager._load_plugin() could not load plugin "rqt_graph/RosGraph":
Traceback (most recent call last):
File "/opt/ros/melodic/lib/python2.7/dist-packages/qt_gui/plugin_handler.py", line 102, in load
self._load()
File "/opt/ros/melodic/lib/python2.7/dist-packages/qt_gui/plugin_handler_direct.py", line 55, in _load
self._plugin = self._plugin_provider.load(self._instance_id.plugin_id, self._context)
File "/opt/ros/melodic/lib/python2.7/dist-packages/qt_gui/composite_plugin_provider.py", line 72, in load
instance = plugin_provider.load(plugin_id, plugin_context)
File "/opt/ros/melodic/lib/python2.7/dist-packages/qt_gui/composite_plugin_provider.py", line 72, in load
instance = plugin_provider.load(plugin_id, plugin_context)
File "/opt/ros/melodic/lib/python2.7/dist-packages/rqt_gui_py/ros_py_plugin_provider.py", line 61, in load
return super(RosPyPluginProvider, self).load(plugin_id, plugin_context)
File "/opt/ros/melodic/lib/python2.7/dist-packages/qt_gui/composite_plugin_provider.py", line 72, in load
instance = plugin_provider.load(plugin_id, plugin_context)
File "/opt/ros/melodic/lib/python2.7/dist-packages/rqt_gui/ros_plugin_provider.py", line 90, in load
raise e
File "/opt/ros/melodic/lib/python2.7/dist-packages/rqt_gui/ros_plugin_provider.py", line 80, in load
attributes['module_name'], fromlist=[attributes['class_from_class_type']], level=0)
File "/home/fzz/.local/lib/python3.6/site-packages/shiboken2/files.dir/shibokensupport/feature.py", line 142, in _import
return original_import(name, *args, **kwargs)
File "/opt/ros/melodic/lib/python2.7/dist-packages/rqt_graph/ros_graph.py", line 45, in <module>
from qt_dotgraph.dot_to_qt import DotToQtGenerator
File "/home/fzz/.local/lib/python3.6/site-packages/shiboken2/files.dir/shibokensupport/feature.py", line 142, in _import
return original_import(name, *args, **kwargs)
File "/opt/ros/melodic/lib/python2.7/dist-packages/qt_dotgraph/dot_to_qt.py", line 35, in <module>
import pydot
File "/home/fzz/.local/lib/python3.6/site-packages/shiboken2/files.dir/shibokensupport/feature.py", line 142, in _import
return original_import(name, *args, **kwargs)
ModuleNotFoundError: No module named 'pydot'
谢谢! -
@fuzz 别在这个板块发哈,先找找对应板块,找不到在综合问题下发
-
-
@小鱼 好的,抱歉,我重新发一下。
-
@fuzz 我已经移过去了
-
@小鱼 好的,谢谢您。
-
@fuzz 还有格式,可以用代码块包裹下,markdown语法在写文档会经常用到,强烈建议使用哦
-
@小鱼 好的,我去了解一下那个软件,抱歉现在还不太懂所以格式不对,给您添麻烦了。
-
@fuzz 在 rosrun报错,ModuleNotFoundError: No module named 'pydot' 中说:
ModuleNotFoundError: No module named 'pydot'
从库的引用上看,估计是又找到了python3上面了,环境应该是有些混乱。