Skip to content

libfetchers: Bump tarball-cache version to v2 [backport 2.33]#14812

Merged
Mic92 merged 1 commit intoNixOS:2.33-maintenancefrom
Mic92:backport-14799-to-2.33-maintenance
Dec 16, 2025
Merged

libfetchers: Bump tarball-cache version to v2 [backport 2.33]#14812
Mic92 merged 1 commit intoNixOS:2.33-maintenancefrom
Mic92:backport-14799-to-2.33-maintenance

Conversation

@Mic92
Copy link
Member

@Mic92 Mic92 commented Dec 16, 2025

Backport of #14799 to 2.33-maintenance.

Resolved conflict by keeping the positional argument style used in 2.33 while applying the tarball-cache-v2 change.


Original PR description:

Unfortunately previous tarball caches had loose objects written to them and subsequent switch to thin packfiles. This results in possibly broken thin packfiles when the loose objects backend is disabled. Thin packfiles do not necessarily contain the whole closure of objects. When packfilesOnly is true we end up with an inconsistent state where a tree lives in a packfiles which refers to a blob in the loose objects backend.

Fixes #14796.

Unfortunately previous tarball caches had loose objects written to
them and subsequent switch to thin packfiles. This results in possibly
broken thin packfiles when the loose objects backend is disabled. Thin
packfiles do not necessarily contain the whole closure of objects.
When packfilesOnly is true we end up with an inconsistent state where
a tree lives in a packfiles which refers to a blob in the loose objects
backend.

In the future we might want to nuke old cache directories and repack
the tarball cache.

(cherry picked from commit 0ffe83a)
@Mic92 Mic92 requested a review from edolstra as a code owner December 16, 2025 19:13
@github-actions github-actions bot added the fetching Networking with the outside (non-Nix) world, input locking label Dec 16, 2025
@Mic92 Mic92 enabled auto-merge December 16, 2025 19:16
@Mic92 Mic92 merged commit 2d5ea36 into NixOS:2.33-maintenance Dec 16, 2025
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fetching Networking with the outside (non-Nix) world, input locking

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants