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

[docs] add note about callback lifetime for {on, post}_set_parameter_callback #1981

Merged
merged 3 commits into from
Aug 29, 2022

Conversation

ihasdapie
Copy link
Member

I've been burned by ignoring the return value and so has a few others -- adding a note about the lifetime of the registered callback being tied to the returned callback handle further up the documentation should help others avoid making the same mistake.

Signed-off-by: Brian Chen brian.chen@openrobotics.org

Signed-off-by: Brian Chen <brian.chen@openrobotics.org>
Copy link
Member

@jacobperron jacobperron left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the same message should also be added to add_pre_set_parameters_callback.

rclcpp/include/rclcpp/node.hpp Outdated Show resolved Hide resolved
Signed-off-by: Brian Chen <brian.chen@openrobotics.org>
Copy link
Collaborator

@fujitatomoya fujitatomoya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Signed-off-by: Brian Chen <brian.chen@openrobotics.org>
@ihasdapie ihasdapie merged commit dab9f5e into rolling Aug 29, 2022
@ihasdapie ihasdapie deleted the brianc/on_post_set_docs branch August 29, 2022 19:14
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

Successfully merging this pull request may close these issues.

None yet

3 participants