Fix #205: bare-hex pack checksums #207
No reviewers
Labels
No labels
actions
bug
cli
duplicate
enhancement
fork
forum
git storage
help wanted
insights
invalid
issues
moderation
oidc
ownership transfer
packages
pr/merge protection rules
projects
pull requests
question
releases
sponsorships
tags
webhooks
wiki
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
crueber/walhub!207
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/issue-205"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Fixes #205: push/import/CLI producers derived PackRef.checksum with TrimSuffix-only on git's on-disk pack-.idx names, keeping the pack- infix in the manifest + bucket keys (wal/pack-.pack) against the 02 §2.2 bare-hex contract, and stacking a new pack- layer per re-ingest. newLocalPack additionally returned hollow claims for pack-less idx files (silent pack-upload skip).
What changed:
Tests (all go test -race green; make cover gate passes, every internal/... package >=95%):
Docs (law 12): Decisions entries in 02 (+wire-contract note), 04, 05, 06 §14, 11 §8, features/10.
Repair/fsck scope: OUT of scope by decision (documented in 02). Old prefixed/duplicated entries stay readable (shape-agnostic readers); compaction folds legacy tier-0 packs into bare tier-1 (supersedes by stored checksum; gcSuperseded deletes old keys post-retention), so live sets converge without a dedicated migration pass.
Deviations: none (stdlib only; pre-1.0 no-alias law respected — no shims, old shape deleted in the same change).
Push/import/CLI repack tails derived PackRef.checksum with TrimSuffix-only on git's on-disk pack-<hex>.idx names, keeping the pack- infix in the manifest and bucket keys (wal/pack-<hex>.pack) against the 02 §2.2 bare-hex contract, and stacking a new pack- layer per re-ingest. newLocalPack additionally returned hollow claims for pack-less idx files (silent pack-upload skip). - internal/git: new PackChecksumFromIdx helper (single source of truth) - internal/server bind_wal.go: strip infix, sibling-derived paths, complete-pair claims only, legacy-known matching (no re-publish) - internal/repoimport task.go, cmd/walhub ops.go: bare checksums + pack-<bare>.pack paths in the FullRepack tails - internal/wal installPackFile: same-file no-op (repack outputs are read-only; self-copy truncated with EACCES) - tests: HTTP push + engine shape matrix + import e2e + mixed-manifest reads + helper unit table; x_gaps{,7,8} updated to the new contract - docs: Decisions entries in 02 (+wire-contract note), 04, 05, 06, 11, features/10; repair/fsck pass out of scope (readers shape-agnostic, compaction converges live sets to bare)