question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Types for creating an Action Client not Updating with Sources Action Message Types

See original GitHub issue

Problem example:

// Variable actionType has to be a certain string value. Types don't update when sourcing additional packages
const newActionClient = new ActionClient(node, actionType as ActionTypeClassName, actionName);

newActionClient.sendGoal(data).then(v => {
  log.debug('Action Complete!');
})

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
wayneparrottcommented, Aug 3, 2020

I’m able to isolate the problem to the slam_toolbox does not follow the ROS naming convention for placing services interfaces (idl) in a folder named srv. Instead slam_toolbox services idl lives in a folder named srvs here.

I’ll submit a PR that is a bit more robust handling of such situations.

A short term workaround is to manually change 1 line of code in node_modules/rclnodejs/rclgen_tsd/index.js line as shown below. 2020-08-02_22-16-33

0reactions
caelinsutchcommented, Aug 1, 2020

Update - Even after deleting generated and even the entire folder and reinstalling, I’m still not getting all my packages sourced. For example, when calling a the service /save_maps from Slamtoolbox, I’m getting the error The message required does not exist: slam_toolbox, srv, SaveMap. In the same terminal window, I can run that service from the command line.

This is from the CLI:


➜ ros2 service type /save_map 
slam_toolbox/srv/SaveMap

Read more comments on GitHub >

github_iconTop Results From Across the Web

Writing a Simple Action Client - ROS Wiki
The action client is templated on the action definition, specifying what message types to communicate to the action server with. The action ......
Read more >
Tutorial 7: communication using actions — 240AR060
Objective: This tutorial session is devoted to learn the ROS synchronous request/response remote procedure calls with feedback and preemption. Contents. Working ...
Read more >
Action client feedback callback does not reliably trigger #1679
My test node sends a goal to the Fibonacci action with order = 5 . I expect the action server to publish 4...
Read more >
ROS Create Custom Action - The Robotics Back-End
Create, compile, and import your custom ROS Actions in your code. ... As you can see we've only used standard ROS data types...
Read more >
Create ROS action client - MATLAB - MathWorks
client = rosactionclient( actionname , actiontype ) creates an action client with the specified name and type ( ActionType ). If the action...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found