ros2 / rclcpp

rclcpp (ROS Client Library for C++)
Apache License 2.0
514 stars 410 forks source link

:farmer: `rclcpp.test_executors` failing in Rolling and Jazzy CycloneDDS #2502

Open Crola1702 opened 2 months ago

Crola1702 commented 2 months ago

Bug report

Required Info:

Steps to reproduce issue

  1. Run a build in Rolling Cyclone CI
  2. Seeprojectroot.test.rclcpp.test_executors fail.

Additional information

Reference build: https://build.ros2.org/view/Rci/job/Rci__nightly-cyclonedds_ubuntu_noble_amd64/41/#showFailuresLink

Test regressions:

Log output TextExecutors spin_some: ``` /tmp/ws/src/ros2/rclcpp/rclcpp/test/rclcpp/executors/test_executors.cpp:572 Expected equality of these values: my_waitable1->get_count() Which is: 1 original_my_waitable1_count + 1 Which is: 2 spin_some() failed to execute a waitable that was triggered ```

spin_some tests is failing since https://github.com/ros2/rclcpp/pull/2465 in CycloneDDS

Log output TestExecutors spin_some_max_duration: ``` /tmp/ws/src/ros2/rclcpp/rclcpp/test/rclcpp/executors/test_executors.cpp:642 Expected: (to_nanoseconds_helper(spin_some_run_time)) > (to_nanoseconds_helper(waitable_callback_duration / 2)), actual: 56575 vs 100000000 spin_some() took less than half the expected time to execute a single waitable, which implies it did not actually execute one when it was expected to /tmp/ws/src/ros2/rclcpp/rclcpp/test/rclcpp/executors/test_executors.cpp:656 Expected equality of these values: number_of_waitables_executed Which is: 0 1u Which is: 1 expected exactly one of the two waitables to be executed, but my_waitable1->get_count(): 0 and my_waitable2->get_count(): 0 ```
Log output TestBusyWaiting spin_all: ``` /tmp/ws/src/ros2/rclcpp/rclcpp/test/rclcpp/executors/test_executors.cpp:952 Expected: (waitable->get_is_ready_call_count()) < (10u * this->waitable->get_count()), actual: 1 vs 0 /tmp/ws/src/ros2/rclcpp/rclcpp/test/rclcpp/executors/test_executors.cpp:975 Expected equality of these values: this->waitable->get_count() Which is: 0 2u Which is: 2 ```

Log output TestBusyWaiting spin_some : ``` /tmp/ws/src/ros2/rclcpp/rclcpp/test/rclcpp/executors/test_executors.cpp:952 Expected: (waitable->get_is_ready_call_count()) < (10u * this->waitable->get_count()), actual: 1 vs 0 /tmp/ws/src/ros2/rclcpp/rclcpp/test/rclcpp/executors/test_executors.cpp:986 Expected equality of these values: this->waitable->get_count() Which is: 0 1u Which is: 1 ```
Crola1702 commented 1 month ago

I updated the information on this issue with new jobs and test regressions

Crola1702 commented 1 day ago

Flaky ratio today (15 days):

job_name last_fail first_fail build_count failure_count failure_percentage
Rci__nightly-cyclonedds_ubuntu_noble_amd64 2024-07-02 2024-06-19 11 11 100.0
Jci__nightly-cyclonedds_ubuntu_noble_amd64 2024-07-02 2024-06-20 5 5 100.0