feat(unpack-objects): supercharge — elapsed_ms, JSON errors to stdout, exit-3, tags_written
- elapsed_ms field in success JSON (renamed from duration_ms for consistency with supercharged tag and trust commands) - _emit_error() helper: JSON mode errors route to stdout so agents always receive parseable output; text mode errors go to stderr - apply_mpack() wrapped in try/except OSError → exit 3 with JSON error (fixes undocumented crash: docstring claimed exit 3 but code never did it) - tags_written added to success JSON and to ApplyResult TypedDict in pack.py (apply_mpack already iterated bundle tags but never counted them) - text-mode output updated to include tags in the summary line - Docstrings updated: error routing contract, JSON error schema, all exit codes - 26 new tests (test_cmd_unpack_objects_supercharge.py): elapsed_ms/exit_code in success JSON, JSON errors to stdout in all error paths, schema completeness, data integrity (exit 1 vs 3 semantics), performance bounds, security (no traceback on any error path including mocked write failures) - Fixed existing test_format_error_to_stderr assertion to match new text output
0 comments
muse hub commit comment sha256:0dc4b2f4193752a7ead353f99b281c4420499fddb2cb6cd2e3c356760ae59253 --body "your comment"
No comments yet. Be the first to start the discussion.