Skip to content
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

[ForwardCommandController] Fix the duplicate command interface types when reconfiguring the controller (backport #1568) #1569

Merged
merged 2 commits into from
Mar 4, 2025

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Mar 4, 2025

if we reconfigure the controller now, it simply appends and creates duplicates. Found the issue with : ros-controls/ros2_control#2090


This is an automatic backport of pull request #1568 done by Mergify.

…when reconfiguring the controller (#1568)

(cherry picked from commit 82c46ac)
@christophfroehlich
Copy link
Contributor

christophfroehlich commented Mar 4, 2025

@saikishor actually, I think that the last assertion of the test JointGroupVelocityControllerTest, ActivateWithWrongJointsNamesFails is wrong, there is nothing set with acceleration (wrong comment, copy-paste error?) and it should succeed

// activate failed, 'acceleration' is not a registered interface for `joint1`
ASSERT_EQ(controller_->on_configure(rclcpp_lifecycle::State()), CallbackReturn::SUCCESS);
ASSERT_EQ(controller_->on_activate(rclcpp_lifecycle::State()), CallbackReturn::ERROR);

the test itself is written badly, because it calls on_configure again from configured state.

Copy link

codecov bot commented Mar 4, 2025

Codecov Report

Attention: Patch coverage is 14.28571% with 6 lines in your changes missing coverage. Please review.

Project coverage is 66.96%. Comparing base (d3caaf1) to head (c9a7199).
Report is 2 commits behind head on humble.

Files with missing lines Patch % Lines
...ollers/test/test_joint_group_effort_controller.cpp 0.00% 0 Missing and 2 partials ⚠️
...lers/test/test_joint_group_position_controller.cpp 0.00% 0 Missing and 2 partials ⚠️
...lers/test/test_joint_group_velocity_controller.cpp 0.00% 0 Missing and 2 partials ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##           humble    #1569   +/-   ##
=======================================
  Coverage   66.95%   66.96%           
=======================================
  Files         115      115           
  Lines       13571    13575    +4     
  Branches     8397     8401    +4     
=======================================
+ Hits         9087     9090    +3     
+ Misses       1423     1415    -8     
- Partials     3061     3070    +9     
Flag Coverage Δ
unittests 66.96% <14.28%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...mand_controller/src/forward_command_controller.cpp 75.00% <100.00%> (+1.31%) ⬆️
...ollers/test/test_joint_group_effort_controller.cpp 55.75% <0.00%> (-0.50%) ⬇️
...lers/test/test_joint_group_position_controller.cpp 58.82% <0.00%> (-0.59%) ⬇️
...lers/test/test_joint_group_velocity_controller.cpp 55.75% <0.00%> (-0.50%) ⬇️

... and 4 files with indirect coverage changes

@christophfroehlich christophfroehlich merged commit 5de2dfa into humble Mar 4, 2025
12 of 13 checks passed
@christophfroehlich christophfroehlich deleted the mergify/bp/humble/pr-1568 branch March 4, 2025 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants