Repository navigation
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed July 11, 2026, 4:23 PM ET / 20:23 UTC. Summary PR surface: Source +1, Tests 0. Total +1 across 2 files. Reproducibility: yes. from source with high confidence: current main can start the bounded retained tail on a low surrogate, and the exact-head regression constructs that boundary for both streams. No actual child or PTY reproduction artifact was supplied. Review metrics: none identified. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance:
Risk before merge
Maintainer options:
Next step before merge
Maintainer decision needed
Security Review detailsBest possible solution: Keep the centralized safe-tail implementation and add a redacted real child or PTY run showing that boundary truncation produces well-formed retained output while streaming remains unchanged. Do we have a high-confidence way to reproduce the issue? Yes, from source with high confidence: current main can start the bounded retained tail on a low surrogate, and the exact-head regression constructs that boundary for both streams. No actual child or PTY reproduction artifact was supplied. Is this the best way to solve the issue? Yes. Fixing the shared capture owner with the existing surrogate-safe helper is narrower and more maintainable than repairing individual RunExit consumers or introducing another truncation path. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against a4c1e2273126. Label changesLabel justifications:
Evidence reviewedPR surface: Source +1, Tests 0. Total +1 across 2 files. View PR surface stats
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
Review history (2 earlier review cycles)
|
7f9b9ab to
c50a653
Compare
|
Maintainer closeout complete on exact head
Ready to land. |
|
Merged via squash.
|
…claw#104531) * fix(process): preserve Unicode in captured output tails * test(process): consolidate captured output coverage --------- Co-authored-by: Peter Steinberger <[email protected]>
What Problem This Solves
Long supervised stdout/stderr is retained behind a truncation marker. When the capture boundary landed between the two UTF-16 code units of an emoji or another non-BMP character, the retained output could contain a lone surrogate and render as a replacement character in downstream consumers such as on-exit run history.
Why This Change Was Made
The process supervisor now uses the repository's canonical
sliceUtf16Safehelper at the capture owner. Streaming callbacks, byte-independent character limits, truncation markers, lifecycle behavior, schemas, and persistence are unchanged.The maintainer refactor folded the regression into the existing bounded-stream test. One test now proves full streaming, per-stream markers, exact bounded tails, and the surrogate boundary without a parallel fixture; the final patch has one net production line and no net test growth.
User Impact
Before: a long command could expose malformed retained output when truncation bisected a surrogate pair.
After: the incomplete pair is dropped and retained stdout/stderr remains well-formed Unicode.
Evidence
src/process/supervisor/supervisor.tssrc/process/supervisor/supervisor.test.tsc50a6534bddccf8d0cf9c983a9cc64d953967641run_56c83697a6cb, public network, no Tailscale, no instance profile, no credential hydrationpnpm test src/process/supervisor/supervisor.test.tsReal behavior proof
Behavior addressed: bounded supervisor capture no longer retains half of a surrogate pair.
Reachability: child/PTY adapter output ->
appendCapturedOutput->RunExit.stdout/RunExit.stderr-> downstream process consumers.Boundary crossed: production capture helper for both output streams, with the test also verifying that unbounded streaming callbacks receive the full original chunks.
Fix classification: root-cause fix.
Proof gap: no additional live gateway run was needed; the changed owner is deterministic and its exact production output projection is covered directly.
AI-assisted (Cursor and Codex)
I understand what the code does
Change is focused and does not mix unrelated concerns