ros-controls / ros2_control

Generic and simple controls framework for ROS 2
https://control.ros.org
Apache License 2.0
479 stars 293 forks source link

Fix spawner tests timeout on source builds (backport #1692) #1697

Open mergify[bot] opened 1 month ago

mergify[bot] commented 1 month ago

As reported by @christophfroehlich in https://github.com/ros-controls/ros2_control/issues/1685, it seems that spawner tests are inconsistent and timing out after some time. I was able to reproduce it locally and upon checking it seems like the CM's internal mutexes are blcoking as there is no ControllerManagerRunner in some of these tests. Adding these should fix the above timeout issues. I've tested it locally and it seems to work

Fixes #1685


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

mergify[bot] commented 1 month ago

Cherry-pick of 079392b94867c3372c0050492327001057118090 has failed:

On branch mergify/bp/humble/pr-1692
Your branch is up to date with 'origin/humble'.

You are currently cherry-picking commit 079392b.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Unmerged paths:
  (use "git add <file>..." to mark resolution)
    both modified:   controller_manager/test/test_spawner_unspawner.cpp

no changes added to commit (use "git add" and/or "git commit -a")

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

codecov[bot] commented 1 month ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 62.31%. Comparing base (9eb64ad) to head (0db5940).

Additional details and impacted files ```diff @@ Coverage Diff @@ ## humble #1697 +/- ## ========================================== + Coverage 62.30% 62.31% +0.01% ========================================== Files 105 105 Lines 11314 11318 +4 Branches 7925 7929 +4 ========================================== + Hits 7049 7053 +4 Misses 806 806 Partials 3459 3459 ``` | [Flag](https://app.codecov.io/gh/ros-controls/ros2_control/pull/1697/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=ros-controls) | Coverage Δ | | |---|---|---| | [unittests](https://app.codecov.io/gh/ros-controls/ros2_control/pull/1697/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=ros-controls) | `62.31% <100.00%> (+0.01%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=ros-controls#carryforward-flags-in-the-pull-request-comment) to find out more. | [Files](https://app.codecov.io/gh/ros-controls/ros2_control/pull/1697?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=ros-controls) | Coverage Δ | | |---|---|---| | [controller\_manager/test/test\_spawner\_unspawner.cpp](https://app.codecov.io/gh/ros-controls/ros2_control/pull/1697?src=pr&el=tree&filepath=controller_manager%2Ftest%2Ftest_spawner_unspawner.cpp&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=ros-controls#diff-Y29udHJvbGxlcl9tYW5hZ2VyL3Rlc3QvdGVzdF9zcGF3bmVyX3Vuc3Bhd25lci5jcHA=) | `59.01% <100.00%> (+0.54%)` | :arrow_up: |