-
Notifications
You must be signed in to change notification settings - Fork 257
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
Bugfix: Recorder discovery does not restart after being stopped #1894
Conversation
Repeated calls to start_discovery should not start additional topics discovery tasks without stop_discovery calls Signed-off-by: Øystein Sture <[email protected]>
The can_record_again_after_stop is failing because it records one more message than expected. If discovery now works between the record calls, it makes sense that it records something else as well, e.g., rosout? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@oysstu thank you for PR and attempt to fix a wrong behavior.
The naming is hard! It seems the root cause of the issue is in unclear naming fo the variable stop_discovery_
.
The logic would be more readable and much easy to understand if stop_discovery_
would be renamed to the discovery_runing_
.
Could you please do such rename in the code and change conditions accordingly?
Signed-off-by: Øystein Sture <[email protected]>
I've made the change, that should clarify the logic a lot. Edit: seemed to pass tests this time |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm with green CI (backport required for jazzy)
Pulls: #1894 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
https://github.com/Mergifyio backport jazzy |
✅ Backports have been created
|
* Invert start discovery condition Repeated calls to start_discovery should not start additional topics discovery tasks without stop_discovery calls Signed-off-by: Øystein Sture <[email protected]> * Rename stop_discovery to discovery_running and change logic accordingly Signed-off-by: Øystein Sture <[email protected]> --------- Signed-off-by: Øystein Sture <[email protected]> (cherry picked from commit b483541)
This is a bug fix for a situation when the discovery in Recorder does not restart after being stopped.
Repeated calls to start_discovery should not start additional topics discovery tasks without stop_discovery calls.