ros2 / rosbag2

Apache License 2.0
285 stars 251 forks source link

Bugfix: Update metadata with new file_info before saving it the first time in the file #1843

Closed MichaelOrlov closed 1 week ago

MichaelOrlov commented 3 weeks ago

This PR is a bug fix for missing file_info for newly created file in saved metadata.

When we are switching to new storage, the correct behavior shall be as follows:

  1. Save metadata to storage
  2. Close current storage
  3. Open new storage for read_write
  4. Update metadata with a newly created file
  5. Save metadata to storage
MichaelOrlov commented 2 weeks ago

@ros-pull-request-builder retest this please

MichaelOrlov commented 2 weeks ago

Pulls: ros2/rosbag2#1843 Gist: https://gist.githubusercontent.com/MichaelOrlov/9e3fdad4ca5ccf152d70e2b2ddfced12/raw/e9f907208e030ed0d619019b76d2f62f11d9917b/ros2.repos BUILD args: --packages-above-and-dependencies rosbag2_compression rosbag2_cpp rosbag2_tests TEST args: --packages-above rosbag2_compression rosbag2_cpp rosbag2_tests ROS Distro: rolling Job: ci_launcher ci_launcher ran: https://ci.ros2.org/job/ci_launcher/14778

christophebedard commented 2 weeks ago

Something weird happened in that Windows job

ahcorde commented 1 week ago
MichaelOrlov commented 1 week ago

https://github.com/Mergifyio backport jazzy

mergify[bot] commented 1 week ago

backport jazzy

✅ Backports have been created

* [#1853 Bugfix: Update metadata with new file_info before saving it the first time in the file (backport #1843)](https://github.com/ros2/rosbag2/pull/1853) has been created for branch `jazzy`