Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[galactic] ctrl+c with tf2_ros imported causes crash on shutdown #546

Open
Kettenhoax opened this issue Aug 2, 2022 · 0 comments
Open
Assignees

Comments

@Kettenhoax
Copy link

Bug report

Required Info:

  • Operating System:
    • Ubuntu 20.04
  • Installation type:
    • binaries
  • Version or commit hash:
    • ros-galactic-tf2-ros 0.17.3-1focal.20220430.135315
  • DDS implementation:
    • cyclonedds
  • Client library (if applicable):
    • rclpy

Steps to reproduce issue

Run the following in bash:

docker run --rm -i ros:galactic python3 - << EOF
import tf2_ros
import rclpy
from rclpy.node import Node
rclpy.init()
try:
  rclpy.spin(Node('test_node'))
except KeyboardInterrupt:
  pass
EOF

and then exit with ctrl+c

Expected behavior

Program exits silently with exit code 0

Actual behavior

Output printed:

^CException ignored in: <function Executor.__del__ at 0xffff8bcdce50>
Traceback (most recent call last):
  File "/opt/ros/galactic/lib/python3.8/site-packages/rclpy/executors.py", line 229, in __del__
  File "/opt/ros/galactic/lib/python3.8/site-packages/rclpy/signals.py", line 41, in destroy
AttributeError: 'NoneType' object has no attribute 'rclpy_unregister_sigint_guard_condition'
Exception ignored in: <function SignalHandlerGuardCondition.__del__ at 0xffff8bcbd0d0>
Traceback (most recent call last):
  File "/opt/ros/galactic/lib/python3.8/site-packages/rclpy/signals.py", line 31, in __del__
TypeError: catching classes that do not inherit from BaseException is not allowed

Additional information

Removing import tf2_ros from the script, or running in the ros:rolling image, leads to the expected behaviour.

The same output was reported in ros2/rclpy#623, but I'm not sure how it is related to the effect of importing tf2_ros.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants