Skip to content

Check for association with an executor before removing nodes in ComponentManager (backport #3190)#3199

Merged
ahcorde merged 1 commit into
lyricalfrom
mergify/bp/lyrical/pr-3190
Jul 16, 2026
Merged

Check for association with an executor before removing nodes in ComponentManager (backport #3190)#3199
ahcorde merged 1 commit into
lyricalfrom
mergify/bp/lyrical/pr-3190

Conversation

@mergify

@mergify mergify Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Description

This PR changes the destructor of component_manager to check each node it's removing for if it is already associated with an executor.

A regression test has also been added to test_component_manager_api in rclcpp_components, which asserts that an exception isn't thrown during the double-removal case as outlined in #3186

Fixes #3186

Is this user-facing behavior change?

  • Users will no longer get an exception on shutdown when using component managers with the callback group events executor

Did you use Generative AI?

Claude Opus 4.8

Additional Information


This is an automatic backport of pull request #3190 done by [Mergify](https://mergify.com).

…nentManager (#3190)

* add a regression test to component manager

Signed-off-by: Skyler Medeiros <skye@polymathrobotics.com>

* test fixture for component manager double shutdown

Signed-off-by: Skyler Medeiros <skye@polymathrobotics.com>

* Check in ComponentManager dtor if node is associated with an executor

Signed-off-by: Skyler Medeiros <skye@polymathrobotics.com>

---------

Signed-off-by: Skyler Medeiros <skye@polymathrobotics.com>
Co-authored-by: Skyler Medeiros <skye@polymathrobotics.com>
(cherry picked from commit d2d94d0)
@mergify

mergify Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor Author

Tick the box to add this pull request to the merge queue (same as @mergifyio queue).

  • Queue this pull request

@ahcorde

ahcorde commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Pulls: #3199
Gist: https://gist.githubusercontent.com/ahcorde/fea1380a810f2365d0935c9532b5fae4/raw/51732d0d7595a92021ec3a859faf38f3d1e1547e/ros2.repos
BUILD args: --packages-above-and-dependencies rclcpp_components
TEST args: --packages-above rclcpp_components
ROS Distro: lyrical
Job: ci_launcher
ci_launcher ran: https://ci.ros2.org/job/ci_launcher/19872

  • Linux Build Status
  • Linux-aarch64 Build Status
  • Linux-rhel Build Status
  • Windows Build Status

@ahcorde
ahcorde merged commit 2fe8eff into lyrical Jul 16, 2026
3 checks passed
@ahcorde
ahcorde deleted the mergify/bp/lyrical/pr-3190 branch July 16, 2026 18:42
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