feat: supercharge muse code lineage — -j alias, exit_code, duration_ms, context fields
- Add -j alias for --json - Add exit_code=0 and duration_ms to JSON output - Add filter/since/until context fields to JSON (agents can verify constraints applied) - Add _LineageJson TypedDict documenting all output keys - Expand run() docstring with JSON envelope section - Fix _classify_replace() docstring (two return values, not three — impl_only was never returned) - Fix module docstring (remove wrong impl_only claim) - Add tests/test_lineage_supercharge.py — 35 tests across 8 classes - Fix pre-existing test_lineage.py failures: commit_id format is sha256:<hex> (71 chars)
sha256:cc395a1951162620c53ae5d8cd7a1f11216da81410707ccee48832f0b244f801
sha
+76
~7
symbols
sha256:7026f12de977c4c16e59944443241f11b5d98658a917912f069ffcc7b414cebf
snapshot
+76
symbols added
~7
symbols modified
0
dead code introduced
Semantic Changes
83 symbols
+
test_signature_change_on_signature_keyword
method
method test_signature_change_on_signature_keyword L549–550
+
test_count_with_json_emits_structured_total
method
method test_count_with_json_emits_structured_total L499–508
+
test_created_event_has_new_content_id
method
method test_created_event_has_new_content_id L342–350
+
test_modified_event_has_old_and_new_content_id
method
method test_modified_event_has_old_and_new_content_id L329–340
+
test_renamed_event_has_detail_in_json
method
method test_renamed_event_has_detail_in_json L352–363
+
test_filter_field_none_when_not_applied
method
method test_filter_field_none_when_not_applied L255–260
+
test_filter_field_present_when_applied
method
method test_filter_field_present_when_applied L245–253
+
test_since_field_in_json_when_applied
method
method test_since_field_in_json_when_applied L262–270
+
test_since_field_none_when_not_applied
method
method test_since_field_none_when_not_applied L282–287
+
test_until_field_in_json_when_applied
method
method test_until_field_in_json_when_applied L272–280
+
test_until_field_none_when_not_applied
method
method test_until_field_none_when_not_applied L289–294
+
test_j_alias_output_matches_json_flag
method
method test_j_alias_output_matches_json_flag L212–221
+
test_filter_returns_empty_for_unmatched_kind
method
method test_filter_returns_empty_for_unmatched_kind L421–430
+
test_invalid_filter_rejected_by_argparse
method
method test_invalid_filter_rejected_by_argparse L432–437
+
test_modified_count_matches_filtered_events
method
method test_modified_count_matches_filtered_events L476–483
+
test_stability_pct_100_when_no_modifications
method
method test_stability_pct_100_when_no_modifications L454–462
+
test_stability_pct_zero_when_all_filtered_to_modified
method
method test_stability_pct_zero_when_all_filtered_to_ L464–474
+
test_lineage_json_typeddict_importable
method
method test_lineage_json_typeddict_importable L527–530
0 comments
To add a comment, use the Muse CLI:
muse hub commit comment sha256:cc395a1951162620c53ae5d8cd7a1f11216da81410707ccee48832f0b244f801 --body "your comment"
No comments yet. Be the first to start the discussion.