gabriel / muse public
refactor BREAKING task/unified-object-store #7 / 9
AI Agent gabriel · 115 days ago · May 20, 2026 · Diff

refactor: remove compute_commit_id/compute_snapshot_id shims; object store is now sole storage layer

Pass 1 — delete compute_commit_id, compute_snapshot_id, snapshot_identity_bytes, and commit_identity_bytes from snapshot.py. Update all 15 call sites across 13 files to import hash_commit / hash_snapshot directly from ids.py.

Pass 2 — flip read priority in read_commit / read_snapshot: object store first, msgpack fallback second.

Pass 3 — write_commit and write_snapshot now write exclusively to the unified object store; dual-write to .muse/commits/ and .muse/snapshots/ removed. commit_exists now checks the object store path.

Pass 4 — remove msgpack fallback read branches from read_commit / read_snapshot; delete .muse/commits/ and .muse/snapshots/ (3,308 legacy msgpack files) from muse repo.

sha256:5b3273e7716eb2c6be5b3bc3d22fb55109192df774314399a5055f90bc3f1c36 sha
+20 ~36 −23 symbols
sha256:d5275471d3ebd7bc821927f1a3724046cbc1aac5289be09e39143eaab1498e23 snapshot
+20
symbols added
~36
symbols modified
−23
symbols removed
0
dead code introduced
Semantic Changes 79 symbols
~ muse/cli/commands/cherry_pick.py .py 2 symbols added, 2 symbols removed, 2 symbols modified
compute_commit_id import import compute_commit_id L59–59
compute_snapshot_id import import compute_snapshot_id L59–59
+ hash_commit import import hash_commit L59–59
+ hash_snapshot import import hash_snapshot L59–59
~ run
~ muse/cli/commands/commit.py .py 2 symbols added, 2 symbols removed, 1 symbol modified
compute_commit_id import import compute_commit_id L52–52
compute_snapshot_id import import compute_snapshot_id L52–52
+ hash_commit import import hash_commit L52–52
+ hash_snapshot import import hash_snapshot L52–52
~ run
~ muse/cli/commands/commit_tree.py .py 1 symbol added, 1 symbol removed, 1 symbol modified
compute_commit_id import import compute_commit_id L75–75
+ hash_commit import import hash_commit L75–75
~ run
~ muse/cli/commands/log.py .py 1 symbol modified
~ muse/cli/commands/merge.py .py 2 symbols added, 2 symbols removed, 2 symbols modified
compute_commit_id import import compute_commit_id L80–80
compute_snapshot_id import import compute_snapshot_id L80–80
+ hash_commit import import hash_commit L80–80
+ hash_snapshot import import hash_snapshot L80–80
~ muse/cli/commands/merge_tree.py .py 1 symbol modified
~ run
~ muse/cli/commands/pull.py .py 2 symbols added, 2 symbols removed, 2 symbols modified
compute_commit_id import import compute_commit_id L56–56
compute_snapshot_id import import compute_snapshot_id L56–56
+ hash_commit import import hash_commit L56–56
+ hash_snapshot import import hash_snapshot L56–56
~ run
~ muse/cli/commands/rebase.py .py 2 symbols added, 2 symbols removed, 2 symbols modified
compute_commit_id import import compute_commit_id L62–62
compute_snapshot_id import import compute_snapshot_id L62–62
+ hash_commit import import hash_commit L62–62
+ hash_snapshot import import hash_snapshot L62–62
~ run
~ muse/cli/commands/revert.py .py 1 symbol added, 1 symbol removed, 1 symbol modified
compute_commit_id import import compute_commit_id L84–84
+ hash_commit import import hash_commit L84–84
~ run
~ muse/cli/commands/shelf.py .py 1 symbol added, 1 symbol removed, 4 symbols modified
compute_snapshot_id import import compute_snapshot_id L86–86
+ hash_snapshot import import hash_snapshot L86–86
~ muse/cli/commands/snapshot_cmd.py .py 1 symbol added, 1 symbol removed, 3 symbols modified
compute_snapshot_id import import compute_snapshot_id L79–79
+ hash_snapshot import import hash_snapshot L79–79
~ muse/core/migrate.py .py 3 symbols added, 1 symbol removed, 4 symbols modified
compute_commit_id import import compute_commit_id L41–41
+ hash_blob import import hash_blob L40–40
+ hash_commit import import hash_commit L40–40
+ hash_snapshot import import hash_snapshot L40–40
~ muse/core/mpack.py .py 1 symbol added, 1 symbol removed, 3 symbols modified
compute_snapshot_id import import compute_snapshot_id L44–44
+ hash_snapshot import import hash_snapshot L44–44
~ muse/core/rebase.py .py 2 symbols added, 2 symbols removed, 2 symbols modified
compute_commit_id import import compute_commit_id L53–53
compute_snapshot_id import import compute_snapshot_id L53–53
+ hash_commit import import hash_commit L53–53
+ hash_snapshot import import hash_snapshot L53–53
~ muse/core/snapshot.py .py 4 symbols removed
commit_identity_bytes function function commit_identity_bytes L459–488
compute_commit_id function function compute_commit_id L491–511
compute_snapshot_id function function compute_snapshot_id L339–350
snapshot_identity_bytes function function snapshot_identity_bytes L314–336
~ muse/core/store.py .py 1 symbol removed, 5 symbols modified
_known_commits_dirs variable variable _known_commits_dirs L1534–1534

0 comments

No comments yet. Be the first to start the discussion.

To add a comment, use the Muse CLI: muse hub commit comment sha256:5b3273e7716eb2c6be5b3bc3d22fb55109192df774314399a5055f90bc3f1c36 --body "your comment"