gabriel / muse public
fix patch task/purge-legacy-object-paths #1 / 1
AI Agent gabriel · 160 days ago · Apr 18, 2026 · Diff

fix: purge all legacy object-store path constructions from tests and migrate.py

- test_cmd_gc_hardening: _write_object() uses write_object()+blob_id(); all hardcoded objects/<shard>/ paths → objects/sha256/<shard>/; symlink tests updated; has_object() replaces path-existence checks - test_prune_supercharge: _object_count() uses iter_stored_objects(); object_path() replaces manual path construction in bytes_freed test - test_commit_object_store_completeness: fix mangled import block; _delete_all_objects uses iter_stored_objects() - test_migrate: _latest_manifest/_all_snapshots prefix snap_id with sha256: when reading back by filename; three inline objects/ walks replaced with iter_stored_objects()/has_object()/object_path(); blob_id() replaces hashlib.sha256().hexdigest() for path-existence checks - migrate.py: oid = blob_id(content) instead of bare hexdigest; imports blob_id from muse.core._types

sha256:6639a894c0a9672cc11c4777695e9ef23ced2bb444e06eb3daee82f190041d01 sha
+33 ~32 symbols
sha256:3708b7c1030dbfb30ae4ab05344fd6212b2587b643935ce7090143777e6e1f40 snapshot
+33
symbols added
~32
symbols modified
0
dead code introduced
Semantic Changes 65 symbols
~ muse/cli/commands/migrate.py .py 1 symbol added, 2 symbols modified
+ blob_id import import blob_id L67–67
+ TestAllObjectsInStoreAfterCommit class class TestAllObjectsInStoreAfterCommit L109–225
+ test_commit_does_not_leave_partial_state_on_apply_manifest_failure method method test_commit_does_not_leave_partial_state_on_apply_manifest_failure L205–225
+ test_first_commit_stores_all_objects method method test_first_commit_stores_all_objects L110–120
+ test_parent_objects_missing_rewritten_on_next_commit method method test_parent_objects_missing_rewritten_on_next_commit L156–203
+ test_second_commit_stores_all_objects method method test_second_commit_stores_all_objects L122–133
+ test_unchanged_file_object_present_after_second_commit method method test_unchanged_file_object_present_after_second_commit L135–154
+ TestApplyManifestAfterCommit class class TestApplyManifestAfterCommit L309–335
+ test_apply_manifest_does_not_raise_after_commit method method test_apply_manifest_does_not_raise_after_commit L310–320
+ test_apply_manifest_does_not_raise_when_parent_objects_were_missing method method test_apply_manifest_does_not_raise_when_parent_objects_were_missing L322–335
+ TestCheckoutAfterCommit class class TestCheckoutAfterCommit L237–298
+ test_checkout_after_commit_with_missing_parent_objects method method test_checkout_after_commit_with_missing_parent_objects L238–269
+ test_checkout_back_and_forth_after_multi_commit_session method method test_checkout_back_and_forth_after_multi_commit_session L271–298
+ _commit function function _commit L57–58
+ _delete_all_objects function function _delete_all_objects L79–85
+ _head_snapshot_manifest function function _head_snapshot_manifest L67–76
+ _init_repo function function _init_repo L61–64
+ _invoke function function _invoke L48–54
+ CliRunner import import CliRunner L30–30
+ annotations import import annotations L23–23
+ get_head_commit_id import import get_head_commit_id L33–33
+ has_object import import has_object L32–32
+ iter_stored_objects import import iter_stored_objects L32–32
+ long_id import import long_id L31–31
+ object_path import import object_path L32–32
+ os import import os L25–25
+ pathlib import import pathlib L26–26
+ pytest import import pytest L28–28
+ read_commit import import read_commit L33–33
+ read_current_branch import import read_current_branch L33–33
+ read_snapshot import import read_snapshot L33–33
+ repo function function repo L94–98
+ runner variable variable runner L40–40
← Older Oldest on task/purge-legacy-object-paths
All commits
Newer → Latest on task/purge-legacy-object-paths

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:6639a894c0a9672cc11c4777695e9ef23ced2bb444e06eb3daee82f190041d01 --body "your comment"