紧急通知:禁止一切关于政治&VPN翻墙等话题,发现相关帖子会立马删除封号
小鱼 ROS 2 新书上线!点击链接查看, 新书配套视频点击链接查看。
提问前必看的发帖注意事项—— 提问前必看!不符合要求的问题拒绝回答!!
社区使用指南—如何添加标签修改密码
小鱼 ROS 2 新书上线!点击链接查看, 新书配套视频点击链接查看。
提问前必看的发帖注意事项—— 提问前必看!不符合要求的问题拒绝回答!!
社区使用指南—如何添加标签修改密码
colcon build 出错:显示cannot import name 'generate_py' from 'rosidl_generator_py'
-
sky0utm@Go:~/yolobot/src$ colcon build
Starting >>> yolobot_control
Starting >>> yolobot_description
Starting >>> yolobot_gazebo
Starting >>> yolobot_recognition
Starting >>> yolov8_msgs
Finished <<< yolobot_gazebo [1.18s]
Finished <<< yolobot_control [1.34s]
Finished <<< yolobot_recognition [1.37s]
Finished <<< yolobot_description [1.52s]
--- stderr: yolov8_msgs
Traceback (most recent call last):
File "/opt/ros/humble/share/rosidl_generator_py/cmake/../../../lib/rosidl_generator_py/rosidl_generator_py", line 8, in <module>
from rosidl_generator_py import generate_py
ImportError: cannot import name 'generate_py' from 'rosidl_generator_py' (/opt/ros/humble/local/lib/python3.10/dist-packages/rosidl_generator_py/init.py)
gmake[2]: *** [yolov8_msgs__py/CMakeFiles/yolov8_msgs__py.dir/build.make:126:rosidl_generator_py/yolov8_msgs/_yolov8_msgs_s.ep.rosidl_typesupport_fastrtps_c.c] 错误 1
gmake[1]: *** [CMakeFiles/Makefile2:590:yolov8_msgs__py/CMakeFiles/yolov8_msgs__py.dir/all] 错误 2
gmake: *** [Makefile:146:all] 错误 2Failed <<< yolov8_msgs [3.77s, exited with code 2]
Summary: 4 packages finished [4.92s]
1 package failed: yolov8_msgs
1 package had stderr output: yolov8_msgs