Skip to content

Make independent verification output and timeouts reliable - #2

Merged
Solarthis merged 1 commit into
mainfrom
maintenance/verifier-reliability-20261006
Nov 10, 2026
Merged

Solarthis merged 1 commit into
mainfrom
maintenance/verifier-reliability-20261006

Conversation

@Solarthis

Copy link
Copy Markdown
Owner

Improvements

  • Ignore blank/non-string package scripts.
  • Redact output before tail truncation.
  • Preserve UTF-8 across stream chunks.
  • Terminate ordinary POSIX descendants on timeout.
  • Omit over-limit streams instead of retaining incomplete secret fragments.
  • Reject invalid time/output limits before spawning.

Verification

73 tests pass including 9 new verifier regressions; TypeScript build passes. Initial 6 regression cases all failed on the baseline. Remote blob hashes match tested files. Existing provider orchestration uses only local fake HTTP servers; real provider smoke/MCP scripts were not run.

Capture overflow intentionally loses that stream's diagnostics. Detached descendants, Windows and actual provider behavior are not certified. See docs/reviews/2026-10-06-verifier.md. Draft only; no deployment or installation.

@Solarthis
Solarthis marked this pull request as ready for review November 10, 2026 10:57

Copy link
Copy Markdown
Owner Author

Review: ready to merge (one non-blocking follow-up)

What it does: Makes the independent verifier's command runner more reliable. Blank or non-string package scripts are ignored. Output is redacted before it is cut to the tail, so a secret can't be half-kept. Multi-byte UTF-8 survives being split across chunks. On timeout, the whole POSIX process group is killed, not just sh. A stream that goes over the 200 KB cap is dropped entirely instead of keeping a fragment. Bad timeout or tail limits are rejected before anything runs.

What I changed: Nothing. The branch is level with main.

Tests (head 1025071): npm ci && npm test passed 73/73, and the tsc build succeeded. CI "test" is green.

Review:

  • Correctness of the new code is good.
  • Residual hang, which the PR doc mentions as uncertified: a descendant that leaves the process group (setsid) and keeps stdout open still blocks close, so verification runs past its timeout. I reproduced it: setsid sleep 8 & sleep 30 with a 1 s timeout was still unresolved after 5 s. Ordinary & children are now killed correctly (resolved at 1.0 s). Suggested follow-up: after a timeout, resolve on the child's exit plus a short grace period and destroy the stdio streams.
  • detached: true also means the command no longer gets Ctrl-C from the parent's terminal. That is fine for an MCP server.
  • Security: redact-then-truncate fixes a real partial-secret leak.

Deploy impact: None. CI on main only runs npm test. Nothing publishes or deploys.


Generated by Claude Code

@Solarthis
Solarthis merged commit 17935b5 into main Nov 10, 2026
1 check passed
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-10T10:57:57.050084Z 1025071 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant