gabriel / muse public
feat patch archive dev
gabriel · 148 days ago · Apr 16, 2026 · Diff

feat(archive): supercharge with --list, enriched JSON, branch resolution, 86-test suite

sha256:b7407814f2dc6ce33554bf8b053a90dae2c2dfd8c0bc18756e68effbc32bc83f sha
+129 ~6 symbols
sha256:60586679e14c14e2e7b7d8cf16eff10b68c1c77d1520b67f9561b12462633afc snapshot
+129
symbols added
~6
symbols modified
0
dead code introduced
Semantic Changes 135 symbols
~ tests/test_archive_command.py .py 126 symbols added
+ TestBuildEntries class class TestBuildEntries L162–200
+ test_entries_sorted_by_arcname method method test_entries_sorted_by_arcname L185–192
+ test_prefix_applied_to_arcnames method method test_prefix_applied_to_arcnames L194–200
+ test_returns_entries_for_valid_manifest method method test_returns_entries_for_valid_manifest L163–175
+ test_skips_missing_objects method method test_skips_missing_objects L177–183
+ TestDataIntegrity class class TestDataIntegrity L729–826
+ test_archive_contains_exactly_manifest_files method method test_archive_contains_exactly_manifest_files L730–740
+ test_committed_at_iso8601 method method test_committed_at_iso8601 L792–801
+ test_file_bytes_match_original method method test_file_bytes_match_original L742–750
+ test_format_choices_complete method method test_format_choices_complete L825–826
+ test_json_bytes_matches_file_size method method test_json_bytes_matches_file_size L814–823
+ test_json_path_field_matches_written_file method method test_json_path_field_matches_written_file L803–812
+ test_list_entries_match_archive_entries method method test_list_entries_match_archive_entries L763–780
+ test_list_entries_sorted method method test_list_entries_sorted L782–790
+ test_zip_bytes_match_original method method test_zip_bytes_match_original L752–761
+ TestDefaultBehavior class class TestDefaultBehavior L284–316
+ test_default_filename_has_no_colon method method test_default_filename_has_no_colon L296–301
+ test_default_filename_no_sha256_prefix method method test_default_filename_no_sha256_prefix L290–294
+ test_exits_0_with_commit method method test_exits_0_with_commit L285–288
+ test_no_commits_exits_1 method method test_no_commits_exits_1 L303–305
+ test_output_includes_commit_short method method test_output_includes_commit_short L312–316
+ test_output_includes_file_count method method test_output_includes_file_count L307–310
+ TestFormatFlag class class TestFormatFlag L319–343
+ test_invalid_format_exits_nonzero method method test_invalid_format_exits_nonzero L340–343
+ test_tgz_short_flag method method test_tgz_short_flag L330–338
+ test_zip_format_flag method method test_zip_format_flag L320–328
+ TestJsonOutput class class TestJsonOutput L450–575
+ test_json_agent_id_and_model_id method method test_json_agent_id_and_model_id L526–535
+ test_json_bytes_positive method method test_json_bytes_positive L496–504
+ test_json_commit_id_matches method method test_json_commit_id_matches L506–514
+ test_json_exits_0 method method test_json_exits_0 L451–458
+ test_json_file_count_correct method method test_json_file_count_correct L486–494
+ test_json_format_field method method test_json_format_field L567–575
+ test_json_has_all_keys method method test_json_has_all_keys L470–484
+ test_json_is_valid method method test_json_is_valid L460–468
+ test_json_prefix_field method method test_json_prefix_field L557–565
+ test_json_ref_null_for_head method method test_json_ref_null_for_head L537–545
+ test_json_ref_set_when_given method method test_json_ref_set_when_given L547–555
+ test_json_snapshot_id_present method method test_json_snapshot_id_present L516–524
+ TestListMode class class TestListMode L394–447
+ test_list_does_not_create_file method method test_list_does_not_create_file L400–405
+ test_list_exits_0 method method test_list_exits_0 L395–398
+ test_list_json_entry_count_matches method method test_list_json_entry_count_matches L440–447
+ test_list_json_schema method method test_list_json_schema L426–438
+ test_list_shows_file_count method method test_list_shows_file_count L413–416
+ test_list_shows_file_paths method method test_list_shows_file_paths L407–411
+ test_list_with_prefix_shows_prefixed_paths method method test_list_with_prefix_shows_prefixed_paths L418–424
+ TestOutputFlag class class TestOutputFlag L372–391
+ test_custom_output_path method method test_custom_output_path L373–377
+ test_missing_output_dir_exits_1 method method test_missing_output_dir_exits_1 L388–391
+ test_output_short_flag method method test_output_short_flag L379–386
+ TestPerformance class class TestPerformance L697–721
+ test_json_output_under_500ms method method test_json_output_under_500ms L714–721
+ test_list_mode_under_300ms method method test_list_mode_under_300ms L706–712
+ test_single_file_archive_under_500ms method method test_single_file_archive_under_500ms L698–704
+ TestRefFlag class class TestRefFlag L346–369
+ test_ref_to_branch method method test_ref_to_branch L347–354
+ test_ref_to_commit_id method method test_ref_to_commit_id L356–364
+ test_unknown_ref_exits_1 method method test_unknown_ref_exits_1 L366–369
+ TestSafeArcname class class TestSafeArcname L117–159
+ test_absolute_rel_path_returns_none method method test_absolute_rel_path_returns_none L134–135
+ test_dot_rel_path_returns_none method method test_dot_rel_path_returns_none L130–132
+ test_dotdot_component_in_rel_path_returns_none method method test_dotdot_component_in_rel_path_returns_none L140–141
+ test_dotdot_in_prefix_returns_none method method test_dotdot_in_prefix_returns_none L143–144
+ test_dotdot_in_rel_path_returns_none method method test_dotdot_in_rel_path_returns_none L137–138
+ test_empty_rel_path_returns_none method method test_empty_rel_path_returns_none L127–128
+ test_nested_path method method test_nested_path L152–153
+ test_null_byte_in_prefix_returns_none method method test_null_byte_in_prefix_returns_none L149–150
+ test_null_byte_in_rel_path_returns_none method method test_null_byte_in_rel_path_returns_none L146–147
+ test_prefix_trailing_slash_stripped method method test_prefix_trailing_slash_stripped L124–125
+ test_prefix_with_subdirs method method test_prefix_with_subdirs L158–159
+ test_simple_path_no_prefix method method test_simple_path_no_prefix L118–119
+ test_simple_path_with_prefix method method test_simple_path_with_prefix L121–122
+ test_single_filename method method test_single_filename L155–156
+ TestSecurity class class TestSecurity L583–634
+ test_prefix_dotdot_error_on_stderr method method test_prefix_dotdot_error_on_stderr L604–607
+ test_prefix_dotdot_rejected_by_cli method method test_prefix_dotdot_rejected_by_cli L599–602
+ test_safe_arcname_blocks_absolute method method test_safe_arcname_blocks_absolute L587–588
+ test_safe_arcname_blocks_dotdot_prefix method method test_safe_arcname_blocks_dotdot_prefix L596–597
+ test_safe_arcname_blocks_null_byte_path method method test_safe_arcname_blocks_null_byte_path L590–591
+ test_safe_arcname_blocks_null_byte_prefix method method test_safe_arcname_blocks_null_byte_prefix L593–594
+ test_safe_arcname_blocks_traversal method method test_safe_arcname_blocks_traversal L584–585
+ test_tar_archive_has_no_traversal_paths method method test_tar_archive_has_no_traversal_paths L615–622
+ test_unknown_ref_does_not_glob method method test_unknown_ref_does_not_glob L609–613
+ test_zip_archive_has_no_traversal_paths method method test_zip_archive_has_no_traversal_paths L624–634
+ TestStress class class TestStress L642–689
+ test_100_file_manifest_tar method method test_100_file_manifest_tar L643–650
+ test_100_file_manifest_zip method method test_100_file_manifest_zip L652–662
+ test_deeply_nested_paths method method test_deeply_nested_paths L672–678
+ test_large_file_content method method test_large_file_content L680–689
+ test_list_mode_100_files method method test_list_mode_100_files L664–670
+ TestTarContents class class TestTarContents L208–246
+ test_no_muse_metadata_in_tar method method test_no_muse_metadata_in_tar L240–246
+ test_tar_contains_all_files method method test_tar_contains_all_files L209–216
+ test_tar_file_contents_match_source method method test_tar_file_contents_match_source L218–226
+ test_tar_prefix_wraps_files method method test_tar_prefix_wraps_files L228–238
+ TestZipContents class class TestZipContents L249–276
+ test_zip_contains_all_files method method test_zip_contains_all_files L250–257
+ test_zip_file_contents_match_source method method test_zip_file_contents_match_source L259–264
+ test_zip_prefix_wraps_files method method test_zip_prefix_wraps_files L266–276
+ _make_commit function function _make_commit L63–109
+ cli variable variable cli L27–27
+ CliRunner import import CliRunner L25–25
+ CommitRecord import import CommitRecord L38–38
+ SnapshotRecord import import SnapshotRecord L38–38
+ _FORMAT_CHOICES import import _FORMAT_CHOICES L29–29
+ _build_entries import import _build_entries L29–29
+ _build_tar import import _build_tar L29–29
+ _build_zip import import _build_zip L29–29
+ _safe_arcname import import _safe_arcname L29–29
+ annotations import import annotations L14–14
+ compute_commit_id import import compute_commit_id L37–37
+ compute_snapshot_id import import compute_snapshot_id L37–37
+ datetime import import datetime L16–16
+ hashlib import import hashlib L17–17
+ json import import json L18–18
+ pathlib import import pathlib L19–19
+ pytest import import pytest L24–24
+ tarfile import import tarfile L20–20
+ time import import time L21–21
+ write_commit import import write_commit L38–38
+ write_object import import write_object L36–36
+ write_snapshot import import write_snapshot L38–38
+ zipfile import import zipfile L22–22
+ repo function function repo L49–60
+ runner variable variable runner L40–40
~ muse/cli/commands/archive.py .py 3 symbols added, 6 symbols modified
+ _ListEntryJson class class _ListEntryJson L185–189
+ _ListJson class class _ListJson L192–229
+ _build_entries function function _build_entries L284–320
~ run
← Older Oldest on dev
All commits
Newer → Latest on dev

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