Fatal error: custom_interfaces/action/move.hpp

I’m facing this problem:

user:~/ros2_ws$ colcon build

Starting >>> custom_interfaces
[0.258s] WARNING:colcon.colcon_ros.prefix_path.ament:The path '/home/user/ros2_ws/install/my_action_server' in the environment variable AMENT_PREFIX_PATH doesn't exist
[0.258s] WARNING:colcon.colcon_ros.prefix_path.ament:The path '/home/user/ros2_ws/install/my_action_client' in the environment variable AMENT_PREFIX_PATH doesn't exist
[0.258s] WARNING:colcon.colcon_ros.prefix_path.ament:The path '/home/user/ros2_ws/install/movement_pkg' in the environment variable AMENT_PREFIX_PATH doesn'texist
[0.259s] WARNING:colcon.colcon_ros.prefix_path.catkin:The path '/home/user/ros2_ws/install/my_action_server' in the environment variable CMAKE_PREFIX_PATH doesn't exist
[0.259s] WARNING:colcon.colcon_ros.prefix_path.catkin:The path '/home/user/ros2_ws/install/my_action_client' in the environment variable CMAKE_PREFIX_PATH doesn't exist
[0.259s] WARNING:colcon.colcon_ros.prefix_path.catkin:The path '/home/user/ros2_ws/install/movement_pkg' in the environment variable CMAKE_PREFIX_PATH doesn't exist
Starting >>> client_pkg
Starting >>> exercise52_pkg
Starting >>> my_action_client
--- stderr: my_action_client
/home/user/ros2_ws/src/my_action_client/src/action_client.cpp:6:10: fatal error: custom_interfaces/action/move.hpp: No such file or directory
    6 | #include "custom_interfaces/action/move.hpp"
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
gmake[2]: *** [CMakeFiles/action_client_node.dir/build.make:76: CMakeFiles/action_client_node.dir/src/action_client.cpp.o] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:137: CMakeFiles/action_client_node.dir/all] Error 2
gmake: *** [Makefile:146: all] Error 2
---
Failed   <<< my_action_client [2.31s, exited with code 2]
Aborted  <<< custom_interfaces [7.30s]
Aborted  <<< client_pkg [7.95s]
Aborted  <<< exercise52_pkg [9.59s]

Summary: 0 packages finished [9.75s]
  1 package failed: my_action_client
  3 packages aborted: client_pkg custom_interfaces exercise52_pkg
  2 packages had stderr output: client_pkg my_action_client
  2 packages not processed

Can you help me ?

That was the error.

  • Is the action properly set up and built
  • Did you make the necessary changes in the action client?

Please review the units Custom Action Interface and Use a Custom Action Interface, and ensure you have made the required changes.

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.