Skip to content

Expect event callbacks only for handlers that were created (backport #3461) - #3465

Merged
ahcorde merged 1 commit into
lyricalfrom
mergify/bp/lyrical/pr-3461
Dec 2, 2026
Merged

ahcorde merged 1 commit into
lyricalfrom
mergify/bp/lyrical/pr-3461

Conversation

@mergify

@mergify mergify Bot commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

Description

disable_enable_event_callbacks (test_subscription) and disable_enable_subscription_event_callbacks (test_generic_pubsub), added in #2985, expect deadline and liveliness callbacks to run. rclcpp creates no handler for an event type the RMW doesn't support (bind_event_callbacks catches it and warns), so on such an RMW the count stays 0 and the test fails although enable/disable works. Expected counts now come from the handlers that exist; skip only if neither exists. This also drops the rmw_zenoh skip in test_generic_pubsub, since test_subscription runs the same body on Zenoh without one and passes.

The tests was added because I'm trying to make a new rmw (rmw_unix_socket_cpp) that doesn't support deadline pass the nightly tests, without adding a new if along the zenoh condition

Is this user-facing behavior change?

No (test only).

Did you use Generative AI?

Yes, Claude Code and I reviewed and tested it
.

Additional Information

Both tests pass with the change on Fast DDS, Cyclone DDS, rmw_zenoh_cpp (the generic one now runs instead of skipping) and rmw_unix_socket_cpp (0 deadline, 1 liveliness callback), tested on Lyrical (rclcpp 32.0.3, same test bodies as rolling).

Why not rmw_event_type_is_supported: rmw_zenoh answers "unsupported" but still creates the handlers, so its callbacks do run.


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

disable_enable_event_callbacks and its generic pubsub twin expect the
deadline and liveliness callbacks to run. rclcpp creates no handler for an
event type the RMW doesn't support (it only warns), so on such an RMW the
count stays at 0 and the test fails although enabling and disabling work.
Derive the expected counts from the handlers that exist and skip only when
there are none.

This drops the rmw_zenoh skip in test_generic_pubsub as well: test_subscription
runs the same body on rmw_zenoh_cpp without a skip and passes.

Claude-Session: https://claude.ai/code/session_012EJmdSvyUzRoZmYQKqLnjQ

Signed-off-by: Abderahmane Benali <46283596+benaliabderrahmane@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit 06702a1)
@ahcorde

ahcorde commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

Pulls: #3465
Gist: https://gist.githubusercontent.com/ahcorde/41e22b99b48425c7b117d2f9eaca1e44/raw/1886b2b072e67ed0b556b764d34be4891b7abf09/ros2.repos
BUILD args: --packages-above-and-dependencies rclcpp
TEST args: --packages-above rclcpp
ROS Distro: lyrical
Job: ci_launcher
ci_launcher ran: https://ci.ros2.org/job/ci_launcher/21443

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

@github-actions

github-actions Bot commented Dec 2, 2026

Copy link
Copy Markdown

ABI Compliance Check

✅ Verdict: compatible

Library Verdict Summary
libcomponent_manager.so ✅ compatible No ABI changes detected.
librclcpp.so ✅ compatible No ABI changes detected.
librclcpp_action.so ✅ compatible No ABI changes detected.
librclcpp_lifecycle.so ✅ compatible No ABI changes detected.
✅ libcomponent_manager.so — full abidiff report

Compared:

  • Base: lib-base/libcomponent_manager.so
  • Head: lib-pr/libcomponent_manager.so @ 944637f
(empty report — no differences printed by abidiff)
✅ librclcpp.so — full abidiff report

Compared:

  • Base: lib-base/librclcpp.so
  • Head: lib-pr/librclcpp.so @ 944637f
(empty report — no differences printed by abidiff)
✅ librclcpp_action.so — full abidiff report

Compared:

  • Base: lib-base/librclcpp_action.so
  • Head: lib-pr/librclcpp_action.so @ 944637f
(empty report — no differences printed by abidiff)
✅ librclcpp_lifecycle.so — full abidiff report

Compared:

  • Base: lib-base/librclcpp_lifecycle.so
  • Head: lib-pr/librclcpp_lifecycle.so @ 944637f
(empty report — no differences printed by abidiff)

Updated for commit 944637f · check run · suppressions: /home/runner/work/_temp/ros2-abi-suppressions.txt

@ahcorde
ahcorde merged commit 8f05477 into lyrical Dec 2, 2026
10 of 11 checks passed
@ahcorde
ahcorde deleted the mergify/bp/lyrical/pr-3461 branch December 2, 2026 16:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants