Snapshot rosdistro dependency metadata - #146
Conversation
|
@traversaro, is there a repository where I could refresh the snapshot and test this change? I originally planned to try it on Jazzy, but I noticed that its full-rebuild PR was recently merged and the rebuild has not yet completed due to some failures. |
|
Or perhaps I could pick up either the Lyrical or Rolling one? Either would be fine with me. |
I would try in rolling. |
|
One thing that I am a bit afraid is that the full cache (like https://repo.ros2.org/rosdistro_cache/rolling-cache.yaml.gz) is ~2 MB uncompressed, so I am not sure if we want to commit it to the repo. I wonder if we can store it somewhere else (but that is tricky to handle seamlessly) or we could somehow store only the dependencies information to avoid storing too much data. |
|
xref: ros/rosdistro#50112, I guess in bazel's ros central registry they had a similar problem. |
I think we could keep the compressed version in the repository, no? The current Rolling cache is only about 211 KiB compressed |
I do not know, I am not a big fan of adding compressed files to a git repo, as they remain in the history forever. But if that the easiest option, no objection for me, but I would like to hear the opinion also of @Tobias-Fischer, @ruben-arts or @baszalmstra . |
|
I might be misunderstanding the question, but if we can download the snapshot cache from the rosdistro repo releases then we can just do that right? |
|
Yeah I would prefer the solution from ros/rosdistro#50112 as well! I am also not a fan of storing the gzipped file in the history. Alternatively we could unpack the files into directories (as text files) and let git do its regular magic. |
To clarify, this PR currently does the following:
This ensures that the snapshot YAML and cache match when they are generated. If an immutable cache corresponding to that exact rosdistro state is available as a release asset, then downloading it later should work. The potential mismatch only occurs if we later download the latest mutable cache: the snapshot YAML may still reference an older package version while the latest cache contains metadata for a newer version. |
That would gives us ~2 MB for snapshot, not sure if I prefer that. |
So between different runs, this information must match? Wouldn't it make more sense to store only that in a file then? Preferably a diff-able text file? |
No, we are downloading the cache of the package.xml of each repo from http://repo.ros2.org/rosdistro_cache, that only contains the latest version. |
If I understand correctly, this would be similar to storing the cache uncompressed. As @traversaro mentioned earlier, the downside is that it would add a roughly 2 MB file unless we post-process the cache and remove the data Vinca does not need. |
If this is the preferred direction, I can try updating this PR |
|
If we only extract the URL, tag, and version from the downloaded file, ideally we only cache that. |
That is what we already store in the snapshot file. But to quickly generate the recipes, we need at least also the dependencies |
5aee14d to
545017a
Compare
|
Does it store it for the packages that are added, or for all packages in the distro? |
|
Thats still quite extensive but better than the gzipped content for sure! I would still prefer ros/rosdistro#50112 but while we wait this is the best solution I think! |
Great. If @traversaro also agrees with this approach, I can include it in my Lyrical full rebuild PR to make sure it doesn't break anything. |
Go for me! |
Signed-off-by: Maurice <mauricepurnawan@gmail.com>
545017a to
45d6e8b
Compare
…ribution-cache Signed-off-by: Maurice <mauricepurnawan@gmail.com> # Conflicts: # vinca/snapshot.py
|
Sorry, I guess there was a conflict with #151, can you please fix the conflicts? Once that is done, it would be great if @baszalmstra could also put the thumbs up. |
…ribution-cache Signed-off-by: Maurice <mauricepurnawan@gmail.com> # Conflicts: # vinca/distro.py
|
Thanks! |


Closes #144.
Summary
A generated entry now looks like:
This avoids committing the complete compressed rosdistro cache or introducing a second snapshot file. Newly generated snapshots contain the metadata Vinca needs for recursive ROS dependency selection while remaining readable and reviewable.
Rolling results
Validation