feat: Phase 5 — pack file support + GC for per-repo object store
- musehub/storage/pack.py: new module with pack_loose_objects, read_packed_object, and gc_packs - pack format: msgpack dict (.pack) + sorted list index (.idx), content- addressed by SHA-256 of sorted object IDs (idempotent) - LocalBackend.get/exists fall through to read_packed_object when loose path is absent; loose takes precedence on hot path - 21 new tests in 7 tiers: creation, read, backend fallthrough, idempotency, GC, result counts, full round-trip
sha256:1d60649537848875b1d90134650925620fe4b15d2e6fa482f136e2c93f9481e9
sha
+52
~3
symbols
sha256:4364fd501c7a96c85e57b83cbb9c55ee071a998c5ec4f1fbb77ee3add725bf73
snapshot
+52
symbols added
~3
symbols modified
0
dead code introduced
Semantic Changes
55 symbols
+
test_gc_keeps_pack_with_unique_objects
method
method test_gc_keeps_pack_with_unique_objects L323–343
+
test_gc_removes_pack_superseded_by_newer_pack
method
method test_gc_removes_pack_superseded_by_newer_pack L301–321
+
test_exists_returns_true_for_packed_object
method
async_method test_exists_returns_true_for_packed_object L207–222
+
test_get_finds_object_in_pack_after_loose_removed
method
async_method test_get_finds_object_in_pack_after_loose_ L188–204
+
test_get_returns_none_when_not_loose_or_packed
method
async_method test_get_returns_none_when_not_loose_or_packed L225–232
+
test_loose_object_takes_precedence_over_pack
method
async_method test_loose_object_takes_precedence_over_pack L235–256
+
test_packing_already_packed_objects_skips_them
method
method test_packing_already_packed_objects_skips_them L281–295
+
test_same_objects_produce_same_pack_name
method
method test_same_objects_produce_same_pack_name L262–279
+
test_packed_count_matches_loose_objects
method
method test_packed_count_matches_loose_objects L360–370
+
test_new_loose_objects_after_pack_are_readable
method
async_method test_new_loose_objects_after_pack_are_readable L423–446
+
test_write_pack_remove_loose_still_readable
method
async_method test_write_pack_remove_loose_still_readable L389–420
+
test_reads_from_correct_pack_when_multiple_exist
method
method test_reads_from_correct_pack_when_multiple_exist L157–181
0 comments
To add a comment, use the Muse CLI:
muse hub commit comment sha256:1d60649537848875b1d90134650925620fe4b15d2e6fa482f136e2c93f9481e9 --body "your comment"
No comments yet. Be the first to start the discussion.