ami-iit / jaxsim

A differentiable physics engine and multibody dynamics library for control and robot learning.
https://jaxsim.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
69 stars 10 forks source link

Move `pixi.lock` to git lfs #189

Closed diegoferigo closed 3 months ago

diegoferigo commented 3 months ago

I've never been fully convinced of the large size of the pixi.lock file directly committed to the git repo. Here below some history of the pixi support and discussions:

After chatting with @flferretti and @traversaro, we decided the following solution to prevent the repo to grow too much in size for the benefit of a very small portion of users:

I believe this is a good trade off that works well for us. We can work on extending the documentation in other PRs.

[!WARNING]
For future readers, keep in mind that GitHub limits the bandwidth from/to the LFS server. If you have many users pushing/pulling LFS files and don't have an upgraded account, you may finish your monthly quota. If this is the case, you might need to find other solutions to prevent having the pixi.lock in your repository.

How to test this PR:

# Clone the repository
cd /tmp
export GIT_LFS_SKIP_SMUDGE=1
git clone -b move_pixi_lock_to_git_lfs https://github.com/ami-iit/jaxsim

# Make sure that the pixi.lock is just 3 lines long
cd jaxsim/
cat pixi.lock | wc -l

# Get the actual pixi.lock from LFS
git lfs pull

# Now the pixi.lock should be ~15k lines long (up to today).

šŸ“š Documentation preview šŸ“š: https://jaxsim--189.org.readthedocs.build//189/

diegoferigo commented 3 months ago

Note: I guess that now we can also add back to the pixi.lock the other architectures and variants that were originally part of https://github.com/ami-iit/jaxsim/pull/134, but then removed because the lock file was excessively large.

diegoferigo commented 3 months ago

I forgot to comment, this PR already contains an updated lock file.

traversaro commented 3 months ago

Note that as now the diff will be quite obscure (and even before they were not super clear given the size of the lockfile) in the future to update the lockfile we could use something like https://pixi.sh/dev/advanced/updates_github_actions/#how-to-use (without the schedule stuff) that adds in the PR a description of the changes.

diegoferigo commented 3 months ago

Note that as now the diff will be quite obscure (and even before they were not super clear given the size of the lockfile) in the future to update the lockfile we could use something like https://pixi.sh/dev/advanced/updates_github_actions/#how-to-use (without the schedule stuff) that adds in the PR a description of the changes.

This is a good idea. We may need to adapt the example to use git lfs, not a big deal though.