-
Notifications
You must be signed in to change notification settings - Fork 493
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Short-circuit planning adapters #1694
Conversation
…ode rather than bool (moveit#1605)" This reverts commit 66a64b4.
Codecov ReportBase: 51.03% // Head: 50.98% // Decreases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## main #1694 +/- ##
==========================================
- Coverage 51.03% 50.98% -0.04%
==========================================
Files 378 378
Lines 31649 31649
==========================================
- Hits 16148 16134 -14
- Misses 15501 15515 +14
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
- Move default code to moveit_core/utils - Override defaults in existing getActionResultString() - Provide translations for all error codes defined in moveit_msgs
658451e
to
44221bd
Compare
I'm fine with the general idea of returning |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generally looks good, I verified functionality
moveit_ros/planning/planning_request_adapter_plugins/src/fix_start_state_bounds.cpp
Show resolved
Hide resolved
moveit_ros/planning/planning_request_adapter_plugins/src/fix_start_state_collision.cpp
Outdated
Show resolved
Hide resolved
moveit_ros/planning/planning_request_adapter_plugins/src/fix_start_state_path_constraints.cpp
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This actually looks simpler. I somewhat like the idea of returning the bool-convertible error code more (which could work just the same way), but either way is fine to me.
moveit_ros/planning/planning_request_adapter_plugins/src/fix_workspace_bounds.cpp
Outdated
Show resolved
Hide resolved
moveit_ros/planning/planning_request_adapter_plugins/src/fix_start_state_path_constraints.cpp
Outdated
Show resolved
Hide resolved
It is simpler and it is removing redundancy (returning the error code by return value and in response). |
Co-authored-by: Henning Kayser <henningkayser@picknik.ai>
Co-authored-by: Henning Kayser <henningkayser@picknik.ai>
This is a simpler implementation of #1605, which is forward-ported from moveit/moveit#3262.
In contrast to #1605 we can keep the existing boolean return types as the error code can be propagated in
res.error_code_
.There is no need to additionally use the return value to propagate an error code. By the way, eventually the propagated return value wasn't used at all, but simply cast back to a boolean:
https://github.com/ros-planning/moveit2/blob/abbbb9d906d21cb7fe2d3ee7c2a2a31799b9d0aa/moveit_ros/planning/planning_pipeline/src/planning_pipeline.cpp#L270-L271
As this PR first reverts #1605, the diff is primarily cluttered by this revert. For review, one ideally compares directly to the original main branch: 749c5ae...rhaschke:moveit2:short-circuit-planning-adapters