Conversation
Signed-off-by: Maurice <mauricepurnawan@gmail.com>
|
Without the patch in ros2/rmw_cyclonedds#607, the tests should fail, as shown in the screenshot below
|
ABI Compliance Check✅ Verdict: compatible
✅
|
|
note: okay now we can see the ABI compliance check result from the forked repository without write permission to the origin. |
|
I think this captures the right regression, but there may be a discovery-timing race in the test itself. Right after creating the publisher and subscription, the test does: ASSERT_EQ(1u, pub->get_subscription_count()); without first waiting for DDS discovery to complete. Elsewhere in the rclcpp tests, endpoint counts are generally treated as asynchronous. For example, "test_subscription.cpp" waits until both publisher/subscription counts become nonzero before continuing, and several other pub/sub tests have similar discovery waits. We probably don't want to use these same two count calls for the wait here, though, because calling them is the operation this regression test is specifically verifying does not consume the pending matched event on CycloneDDS. Could the test first wait for the endpoints to appear through graph-level discovery / endpoint info, then call "get_subscription_count()" and "get_publisher_count()" once to exercise the bug, and only after that spin the executor and assert both pending matched callbacks arrive? That would keep the important RED/GREEN property against rmw_cyclonedds#607 while separating "DDS discovery completed" from "the count query did not consume the event". AI assistance disclosure: reviewed with OpenAI ChatGPT GPT-5.6 Sol. |
|
Pulls: #3279, ros2/rmw_cyclonedds#607 |
|
Note backport required to lyrical kilted jazzy |

Description
Regression test for ros2/rmw_cyclonedds#607
PublisherBase::get_subscription_count()andSubscriptionBase::get_publisher_count()are count queries. Calling them shouldnot prevent an already-pending matched-event callback from being delivered.
A CycloneDDS RMW implementation issue caused these queries to read and reset the
underlying DDS matched status. This made the matched callbacks time out when the
count was queried.
Is this user-facing behavior change?
Yes for cyclonedds only, but not a change in rclcpp
Did you use Generative AI?
Yes, Codex 5.6 Sol
Additional Information