ros2 / examples

Example packages for ROS 2
Apache License 2.0
681 stars 308 forks source link

Update python nodes SIGINT handling #372

Closed thomasmoore-torc closed 2 months ago

thomasmoore-torc commented 4 months ago

Bug report

rclpy was updated to automatically handle SIGINT as part of this PR which was incorporated into the Humble release: https://github.com/ros2/rclpy/pull/844

The python nodes in the demos repository were subsequently updated via the following PRs, but those changes were never incorporated into the examples repository.

For consistency, and to ensure that an exception is not thrown when SIGINT is passed to the example python nodes, these same changes should be incorporated into this repository.

fujitatomoya commented 4 months ago

@thomasmoore-torc thanks for creating issue.

https://github.com/ros2/demos/pull/539

i think https://github.com/ros2/examples/pull/330 aligns with?

https://github.com/ros2/demos/pull/555 https://github.com/ros2/demos/pull/581

those seem like missing?

thomasmoore-torc commented 4 months ago

@fujitatomoya - it looks like #330 only updated the rclpy/executors examples but not any of the other rclpy examples (e.g. rclpy/topics/minimal_publisher/examples_rclpy_minimal_publisher/publisher_local_function.py).