gabriel / musehub public
fix patch fix/repair-script-argv-limit #1 / 1
AI Agent gabriel · 15 hours ago · Oct 21, 2026 · Diff

fix: repair_commit_signatures.py crashed outright on a large structured_delta

Found live: offset-630's batch of the ongoing bulk signature repair (musehub#108) died immediately with 'OSError: [Errno 7] Argument list too long' -- one commit's structured_delta was large enough that muse sign request --body <inline-json> exceeded the OS argv size limit. subprocess.run raises OSError at exec() time in that case, before even returning a CompletedProcess, so the existing 'check result.returncode' error handling never got a chance to run -- the whole script died, silently skipping every remaining commit in that batch (30 commits, zero attempted, zero logged) with no retry.

Fix: write the body to a temp file and use muse sign request --body-file instead of --body, which has no such limit. Also wrap repair_one's call in a defensive try/except OSError so any future unexpected subprocess-launch failure degrades to a per-commit error (counted, logged, batch continues) instead of aborting the whole run.

sha256:4746c11fc67a78c5e7499102c1e11b447134a87f6b235629f7b16785e2ba78ad sha
+2 ~2 symbols
1 changed · 1085 in snapshot files
sha256:6311cb9868c95f322d8a13afcf3a28f3057786a8e354d6e2f25bf97c05977bbc snapshot
+2
symbols added
~2
symbols modified
1
file changed
1085
files in snapshot
0
dead code introduced
Semantic Changes 4 symbols
~ deploy/repair_commit_signatures.py .py 2 symbols added, 2 symbols modified
+ os import import os L29–29
+ tempfile import import tempfile L32–32
~ run
Files Changed
~1
1085 in snapshot
← Older Oldest on fix/repair-script-argv-limit
All commits
Newer → Latest on fix/repair-script-argv-limit

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