-
Notifications
You must be signed in to change notification settings - Fork 522
Closed
Description
Bug report
Required Info:
- Operating System:
- Ubuntu 24.04
- Installation type:
- Jazzy binaries (but reproducible from source, bisected to the commit linked below which introduced the issue)
- Version or commit hash:
- I bisected and found the exact commit that introduced this behavior (it was OK before): 5632a09
- DDS implementation:
- Cyclone
- Client library (if applicable):
- rclcpp
Steps to reproduce issue
- Build my "minimal" reproducible repo https://github.com/luca-della-vedova/timer_repro.
- Run the node
- In another terminal (in this order!):
ros2 lifecycle set /minimal_timer configure
ros2 lifecycle set /minimal_timer activate
ros2 run examples_rclcpp_minimal_service service_main
Expected behavior
Since the service callback destroys only timer_, timer2_ should keep running and Hello, world! should keep printing.
Actual behavior
All timers are stopped and no Hello, world! is printed.
Additional information
The following might shed some light into this.
- If the timer that is erronously not triggered is initialized in the constructor, rather than in a lifecycle transition, the issue does not arise.
- If the action server is ran before the lifecycle transition (which means
timer2_is only created aftertimer_is destroyed) the issue does not arise. - If I manually add a
|| truehere making this condition always evaluate to true, all timers are executed, however I added some printing when timers are cleaned up / added and I can see that every iteration a timer gets added and removed, so something odd is going on there.
So I suspect there is something about how timers (and maybe other entities?) are added to wait sets inside lifecycle node transitions that creates this issue.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels