robomaster_ros
robomaster_ros copied to clipboard
Can't compose Dockerfile during 'colcon build'
The error msg are as follows:
Step 12/12 : RUN mkdir -p /ros_ws/src && cd /ros_ws && git clone https://github.com/jeguzzi/robomaster_ros.git src/robomaster_ros && source /ros_entrypoint.sh && colcon build --install-base /opt/ros/humble --merge-install && rm -r /ros_ws
---> Running in 5d2abbf093c0
Cloning into 'src/robomaster_ros'...
Starting >>> robomaster_msgs
Starting >>> robomaster_description
Finished <<< robomaster_description [0.62s]
--- stderr: robomaster_msgs
CMake Error at /opt/ros/humble/share/rosidl_adapter/cmake/rosidl_adapt_interfaces.cmake:59 (message):
execute_process(/usr/bin/python3.10 -m rosidl_adapter --package-name
robomaster_msgs --arguments-file
/ros_ws/build/robomaster_msgs/rosidl_adapter__arguments__robomaster_msgs.json
--output-dir /ros_ws/build/robomaster_msgs/rosidl_adapter/robomaster_msgs
--output-file
/ros_ws/build/robomaster_msgs/rosidl_adapter/robomaster_msgs.idls) returned
error code 1:
/usr/bin/python3.10: No module named rosidl_adapter
Call Stack (most recent call first):
/opt/ros/humble/share/rosidl_cmake/cmake/rosidl_generate_interfaces.cmake:130 (rosidl_adapt_interfaces)
CMakeLists.txt:39 (rosidl_generate_interfaces)
---
Failed <<< robomaster_msgs [0.69s, exited with code 1]
Summary: 1 package finished [1.12s]
1 package failed: robomaster_msgs
1 package had stderr output: robomaster_msgs
1 package not processed
ERROR: Service 'driver' failed to build: The command '/bin/bash -c mkdir -p /ros_ws/src && cd /ros_ws && git clone https://github.com/jeguzzi/robomaster_ros.git src/robomaster_ros && source /ros_entrypoint.sh && colcon build --install-base /opt/ros/humble --merge-install && rm -r /ros_ws' returned a non-zero code: 1
It seems that /usr/bin/python3.10 can't find a module called rosidl_adapter.
So I have tried add a command in Dockerfile that install rosidl_adapter by RUN apt-get install ros-humble-rosidl-adapter
. Then it says it's already installed, and shows this same error msg again.