gabriel / muse public
feat patch status task/untracked-count #1 / 1
AI Agent gabriel · 110 days ago · May 26, 2026 · Diff

feat(status): add untracked_count field to muse status --json

total_changes counts only tracked-file changes — touching an untracked file left total_changes=0 while dirty=true, creating a semantic gap for callers that want to distinguish the two conditions.

untracked_count = len(untracked) is a convenience field that makes the untracked-only case explicit without changing the total_changes formula (which callers rely on as an invariant).

Adds 6 new schema invariant tests (V1–V6) and updates agent-guide.md with the distinction between total_changes and untracked_count.

sha256:e0303a48b13f62be0a5ae89704792c73bad0143434ed10c7cfc0b46feb7c097c sha
+7 ~22 symbols
sha256:6dc0141f218703c412b8961df282808b11434236017bbc2d12b9f61e2dd38f51 snapshot
+7
symbols added
~22
symbols modified
0
dead code introduced
Semantic Changes 29 symbols
~ tests/test_status_json_schema.py .py 7 symbols added, 3 symbols modified
+ TestUntrackedCountV class class TestUntrackedCountV L418–495
+ test_V1_untracked_count_always_present_as_int method method test_V1_untracked_count_always_present_as_int L419–427
+ test_V2_untracked_count_equals_len_untracked method method test_V2_untracked_count_equals_len_untracked L429–441
+ test_V3_untracked_count_zero_for_clean_repo method method test_V3_untracked_count_zero_for_clean_repo L443–448
+ test_V4_untracked_count_zero_when_only_tracked_changes method method test_V4_untracked_count_zero_when_only_tracked_changes L450–461
+ test_V5_untracked_count_nonzero_total_changes_stays_zero method method test_V5_untracked_count_nonzero_total_changes_stays_zero L463–478
+ test_V6_both_tracked_changes_and_untracked_files method method test_V6_both_tracked_changes_and_untracked_files L480–495
← Older Oldest on task/untracked-count
All commits
Newer → Latest on task/untracked-count

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