fix: apply_manifest only deletes tracked files; _walk_tree stages dotfiles
Two data-safety bugs fixed:
1. apply_manifest(root, prev_manifest, target_manifest) — new 3-arg signature. Deletion candidates come from prev_manifest.keys() instead of walk_workdir(), so untracked files (Write tool docs, local scripts) are never deleted.
2. _walk_tree in code_stage.py — removed dotfile skip. muse code add . now stages .museattributes, .museignore, and other dotfiles just as git add . stages .gitattributes and .gitignore.
All callers updated. 196 tests pass.
sha256:55a8bbec0d35d504592b28a75462e1010cfed70023c31283d5057e577347cd8f
sha
+11
~57
−2
symbols
sha256:acdbb52fcb78d43ef8dc7380c61e8e21613d35603481cb6ce620617893afd404
snapshot
+11
symbols added
~57
symbols modified
−2
symbols removed
0
dead code introduced
Semantic Changes
70 symbols
~
run
~
run
~
run
~
run
−
test_I3_apply_manifest_with_empty_target_deletes_all_tracked_files
method
method test_I3_apply_manifest_with_empty_target_deletes_all_tracked_files L202–243
+
test_I3_apply_manifest_with_empty_target_raises_when_prev_non_empty
method
method test_I3_apply_manifest_with_empty_target_raises_when_prev_non_empty L202–224
−
test_II7_empty_manifest_non_empty_workdir_raises_value_error
method
method test_II7_empty_manifest_non_empty_workdir_raises_value_error L363–370
+
test_II7_empty_manifest_non_empty_prev_raises_value_error
method
method test_II7_empty_manifest_non_empty_prev_raises_value_error L368–375
+
test_IX1_untracked_file_not_deleted_by_apply_manifest
method
method test_IX1_untracked_file_not_deleted_by_apply_manifest L1126–1146
+
test_IX2_untracked_dotfile_not_deleted
method
method test_IX2_untracked_dotfile_not_deleted L1148–1164
+
test_IX3_tracked_file_removed_from_target_gets_deleted
method
method test_IX3_tracked_file_removed_from_target_gets_deleted L1166–1178
+
test_IX4_commit_does_not_delete_untracked_file
method
method test_IX4_commit_does_not_delete_untracked_file L1180–1206
← Older
Oldest on task/commit-id-v2
All commits
Newer
fix: migrate tests to commit-id-v2 (branch→created_on_branch, co…
sha256:6b6e63d804f829df8580591dc85e98ac540b9dfcac10529a291c97c1c04a6dbc
0 comments
To add a comment, use the Muse CLI:
muse hub commit comment sha256:55a8bbec0d35d504592b28a75462e1010cfed70023c31283d5057e577347cd8f --body "your comment"
No comments yet. Be the first to start the discussion.