BehaviorTree.ROS2 icon indicating copy to clipboard operation
BehaviorTree.ROS2 copied to clipboard

Add the ability for ros actions nodes to get access to the action result even on failure

Open JayHerpin opened this issue 1 year ago • 1 comments

The current implementation assumes that if the Ros Action is aborted or otherwise fails that the result returned from the action server is not meaningful. However,there are some cases where that is not true. Consider nav2/action/NavgiateThroughPoses which has an error code in the result. That error code is basically only applicable when the action fails!

The proposed implementation maintains API compatibility. If the user cares about the result, they can implement the newly added virtual method.

Note that result is nullopt on any code paths where a result is not available.

JayHerpin avatar Jun 27 '24 16:06 JayHerpin

IMO, this is the downside of PImpl. If a needed callback is missing, it's really hard to add it via child class, because everything is extra private.

(Or maybe it's an upside? Because it forces you to patch the library. Which you can then submit as a PR!)

b-adkins avatar Jan 04 '25 01:01 b-adkins

looks good to me. thanks again

facontidavide avatar Oct 30 '25 05:10 facontidavide