I’m trying to submit the actions quiz. Both the packages work correctly when I run them in my environment (colcon build --packages-select actions_quiz_msg actions_quiz).
However, when I submit the quiz, the autocorrect system compiles “actions_quiz” before “actions_quiz_msg”. (i.e. colcon build --packages-select actions_quiz actions_quiz_msg)
Since my “actions_quiz” depends on “actions_quiz_msg” (as in CMakeLists.txt file), the autograder fails.
The issue is that you forgot to place the build dependency in the package.xml of /home/user/ros2_ws/src/actions_quiz/package.xml:
Execute this command to check that its solved:
cd ~/ros2_ws/;rm -rf build install log;colcon build --packages-select actions_quiz actions_quiz_msg
You need to specify this otherwise ROS doesn’t know the order of compilation. I know its a bit confusing because in theory stating it in the CMakelists.txt should be enough for the colcon build to know that we have to compile that package before the main one… BUt that’s how it works
Thank you so much! That worked perfectly.
This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.