-
Notifications
You must be signed in to change notification settings - Fork 260
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
[jazzy] Upstream quality changes from Apex.AI part 1 (backport #1903) #1909
Conversation
* Make sure to start with clean subscriptions list in Recorder::record() - It could be some residual subscriptions in list in case if previous call to Recorder::record() failed for some reason and Recorder::stop() wasn't called. Signed-off-by: Michael Orlov <michael.orlov@apex.ai> * Fix clang16 warning that timestamp comparator is not initialized Signed-off-by: Michael Orlov <michael.orlov@apex.ai> * Address Axivion warnings in rosbag2_py 1. MisraC++2023-8.1.1 [required]: _transport.cpp:286 This variable shall not be implicitly captured in a lambda expression.; Field: [] 2. MisraC++2023-8.2.3 [required]: _transport.cpp:50 Cast removes const qualification; Field: [const char*->char*] Signed-off-by: Michael Orlov <michael.orlov@apex.ai> * Gracefully handle exceptions from on-play callbacks in player Signed-off-by: Michael Orlov <michael.orlov@apex.ai> * Move wait_for_playback_to_start() to public section - Rationale: Need to use in another package - Added timeout parameter for the wait_for_playback_to_start(..) to make it non-blocking call optionally and return boolean value. Signed-off-by: Michael Orlov <michael.orlov@apex.ai> * Fix memory leaks in tests - Use custom deleter when releasing rcl serialized buffer to a shared pointer. Signed-off-by: Michael Orlov <michael.orlov@apex.ai> * Don't keep trying to publish next message if we failed first time - The Player::play_next() should return false right away if for some reason failed to publish current message. Signed-off-by: Michael Orlov <michael.orlov@apex.ai> * Wrap run_play_msg_pre_callbacks(message) in its own try-catch - Also added `play_next_returns_false_if_pre_callback_throw_exception` unit test. Signed-off-by: Michael Orlov <michael.orlov@apex.ai> * Use absolute path instead of relative path in the InfoEndToEndTestFixture Signed-off-by: Michael Orlov <michael.orlov@apex.ai> * Call discovery_future_.get() if it's ready in the `stop_discovery()` - Also add missing `include <unordered_set>` Signed-off-by: Michael Orlov <michael.orlov@apex.ai> * Move wait_for_playback_to_start(..) declaration and fixed wording Signed-off-by: Michael Orlov <michael.orlov@apex.ai> --------- Signed-off-by: Michael Orlov <michael.orlov@apex.ai> (cherry picked from commit 871a447) # Conflicts: # rosbag2_transport/src/rosbag2_transport/player.cpp
Cherry-pick of 871a447 has failed:
To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally |
- Adjust for missing "Replay by sent timestamp" feature on Jazzy. Signed-off-by: Michael Orlov <michael.orlov@apex.ai>
Pulls: #1909 |
This PR consolidates fixes related to the code quality and stability after backporting Rosbag2 PRs to Apex.AI. PART 1
List of changes:
Details: Need to use custom deleter when releasing rcl serialized buffer to a shared pointer.
Rationale: Avoid abnormal termination in case of unhandled exceptions happening in callbacks.
Description:
Rationale: It could be some residual subscriptions in the list in case if the previous call to Recorder::record() failed for some reason and Recorder::stop() wasn't called.
stop_discovery()
InfoEndToEndTestFixture
Player::play_next()
should return false right away if, for some reason, failed to publish the current message.This is an automatic backport of pull request Upstream quality changes from Apex.AI part 1 #1903 done by Mergify.