-
Notifications
You must be signed in to change notification settings - Fork 412
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
RCLCPP_FATAL does not exit the program. #1869
Comments
Looking at other logging libraries, their equivalent of
So I think |
I think not crashing makes sense to me. Logging the error and how to shut down are separate concerns, and especially in robotics just dying outright is not necessarily an option all the time. |
That's fine. Thanks for the clarification. I asked primarily because this PR review comment is also expecting the program to exit, which gave me some doubts... This then would be a downstream issue. |
Bug report
Required Info:
Steps to reproduce issue
Compile and run this program:
Expected behavior
RCLCPP_FATAL
should exit this program. Looking at past PR reviews, @wjwwood also expected this in this comment, if I understand that correctly.Actual behavior
I see
Additional information
Originally discovered here: moveit/moveit2#734 (comment). In that case, a downstream consumer project (moveit2) is using
RCLCPP_FATAL
thinking that it will crash the program. However, it doesn't. This leads to nullptr exceptions later.However, simply "fixing" this can have unintended side effects either. A search across Github with
RCLCPP_FATAL
reveals projects where they clearly know that the FATAL macro doesn't exit the program. Fixing this could break backward compatibility and be a bit problematic for them.The text was updated successfully, but these errors were encountered: