Error executing action using roslibjs [closed]

asked 2023-03-15 07:16:15 -0500

updated 2023-03-15 07:22:05 -0500

Hi!

When I start a minimal-example using roslibjs in React+Typescript with ROS noetic I am getting the following error:

publish: Message type mission_execution/MissionControlGoal does not have a field goal_id

on the ros-side that runs the websuite-server.

The goal.goalMessage of the goal that gets send to the server looks like this:

'{"goal_id":{"stamp":{"secs":0,"nsecs":0},"id":"goal_0.3649984460870699_1678882100060"},"goal":{"mission_name":"test_mission"}}'

So this has a goal_id, but the generated file in catkin_ws/devel/share/mission_execution/msg/MissionControlGoal.msg doesn't have a goal_id.

and I define my goalMessage without an goal_id:

  const goal = new ROSLIB.Goal({
      actionClient: missionControlClient,
      goalMessage: new ROSLIB.Message({
        mission_name: 'test_mission'
      })
    });

I think it might be a bug in the roslibjs implementation of actionlib or a mismatch of versions?

My full code is here, you can either install and run the docker container or install and run everything locally. https://github.com/brean/roslibjs-rea...

edit retag flag offensive reopen merge delete

Closed for the following reason question is not relevant or outdated by brean
close date 2023-03-15 10:40:38.698844

Comments

I think I solved it by providing the correct MissionControlAction-name, but I also changed some other stuff, so it seems to work on the current main branch and I close this question.

brean gravatar image brean  ( 2023-03-15 10:40:05 -0500 )edit