[Bug] Auto grader failing - Can't find packages

This is an error report.

Screenshot of the error

Error details

The autograder fails to find the required packages, services_quiz and services_quiz_srv even though they exist. Before running the auto grader, I can see them via "ros2 pkg list | grep services" (See screenshot), but after running auto grader I cannot see them. Also, using the service server and client work when calling their respective launchfile manually, so all should be in order for the quiz. The auto grader should be able to see them at the very least.

Can you include a screenshot of the message of the autograder?

The problem is that one of your quiz packages has an external dependency, custom_interfaces, that should not be there. Remove this dependency.

You should be able to compile and run your quiz packages without any external dependency:

cd ~/ros2_ws
rm -rf build/ install/ log/
colcon build --packages-select services_quiz services_quiz_srv

no occurances
In the services_quiz and services_quiz_srv packages, there are now no mentions of this custom_interfaces depedency.

Following your steps:

cd ~/ros2_ws
rm -rf build/ install/ log/
colcon build --packages-select services_quiz services_quiz_srv

and still get a failed quiz. Also, I am now out of tries for the quiz, is it possible to add more? Thanks.

What is the output you get when you run the above commands? Was the compilation successful? Please show us the output of those commands here.

Also, it appears you are using symbolic links for some packages. If so, please remove them, because the grader will not be able to resolve those links.

I built the packages one at a time, since services_quiz depends on Spin.srv to be built first.
I am not sure how to remove symbolic links. How can you tell this is a problem? Thanks!

If you didn’t create any symbolic links manually, then don’t worry about this.

I think this is the problem. You should be able to build both packages together.

You should have set services_quiz_srv as a dependency when creating services_quiz. That way, colcon would know it has to compile services_quiz_srv first. Kindly revise your packages so that it works that way (compiling them together).

1 Like

Thanks @bayodesegun, this was the solution. I had added the dependency in CMakeLists.txt but forgot to add to package.xml. Thanks for the help.

1 Like

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