ROS Basics in 5 Days Husky Exam

What is the action server in the Husky Maze challenge looking for (a certain number of positions, the entire Odometry data set, etc.)? It is the only error I have on the exam for the course and I cannot figure out what is wrong with the action server result.

Hi @jordan.a.smith,

Welcome to the Community!

To help you better and faster, could you please provide more details? About the error you mentioned and the specific exam you are talking about.

Hi! This is regarding the ROS Basics in 5 days Husky Exam.

Here is a screen shot of the auto-grader output:

The action server is fully operational but my guess is I am not delivering the exact message type the grader is expecting. My action server currently returns OdomData.pose.pose.position but I am wondering if it requires a different data type to be returned?

Hi again!

Your are right, your action server should return a message type of YourActionResult, not a Position or any other message.

If you follow the example given in the notebook, your server code should end with something like:

self._as.set_succeeded(self._result)
# the `self` variable here may not be necessary if you are not using a class as was done in the example
# `_as` is your action server variable
# `_result` is your action's Result message.

And this should return the right kind of message for you.

Got it. My action sever return does look like that and is properly returning data. I believe the issue is with the specific data set I return in that result object. I believe the grader is expecting a different data type than the one I am currently placing as the result. Here is my call back function (action server goal):

def odom_callback(self, DataPoint):
rospy.sleep(1)
self.ResultObj.data.append(DataPoint.pose.pose.position)

The result action message data attribute is currently set as the x,y,z coordinate data. Is the auto grader expecting a different section of data to be returned (position + orientation, entire Pose variable, etc.)?

Thank you for your help thus far.

I think the problem might be that the call -> execute -> response cycle for the action server might have some issues or unexpected results.

Did you try calling the action server from a terminal? Did it execute cleanly without errors?
Did you define the action message as expected? Is there something in the action server response that indicates that it succeeded?