Repository navigation
✨ feat: extensions: check an extension's answer under --json - #42
Conversation
c96ebbf to
d17d69f
Compare
b32600b to
21e7439
Compare
|
2nd pass: by Opus-5.5 via Claude Code |
d17d69f to
ee42fb1
Compare
21e7439 to
a6f2027
Compare
|
Review round 1 (Codex GPT-6.1-Sol, xhigh): 3 findings, all fixed in this layer.
Each new case was checked against the old binary: every behavior case fails on the old code, and the by Opus-5.5 via Claude Code |
ee42fb1 to
ed50a1b
Compare
a6f2027 to
ce9c0e2
Compare
ed50a1b to
9a7841c
Compare
27f9347 to
ffe4195
Compare
0359ce5 to
e13039f
Compare
ffe4195 to
68c8db1
Compare
|
Cross-stack review, round 1 (Codex GPT-6.1-Sol, xhigh), kept in this layer: the answer check and the manifest share one regex for the form of a code, so the two rules cannot drift, and by Opus-5.5 via Claude Code |
- Purpose: M01-T3 asks core to hold an extension's stdout and the last line of its stderr until it exits, and to pass the answer on only when the eight rules of Answer check hold, as D050 decides - Impact: a broken answer becomes RUNTIME with exit 1 and never reaches the caller, a report answers on stdout with exit 78, a text result passes through, an unknown code keeps the meaning of its exit code, and --json selects non-interactive mode, as D046 decides Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
e13039f to
5de8dad
Compare
|
Fixed PRIS1's P2, found in pass 2, in this layer's commit, now 5de8dad. Core dropped the answer's data when it could not write a valid answer to stdout. Before: when Now: core writes the answer to stderr with
Scenario (
The restack touched #43 to #50. Each layer from #43 up changes only
by Opus-5.5 via Claude Code |
Why
M01-T3 asks core to hold an extension's answer under
--jsonand pass it on only when the eight rules of Answer check hold, as D050 decides, so a broken answer never reaches the caller.Scope
internal/contract/answercheck.go:CheckAnswerapplies the eight rules to aReply, andReply.OnStdoutplaces the answer: on stdout for a success and for a report with exit 78internal/cli/dispatch.go: under--json, core holds stdout and passes every stderr line on except the latest, which may be the answer. A text result passes throughcontract.DetectModetakes the resolved--json, as D046 decidesManifestErrorbecomesRuleError, because the answer check uses it toocompat_test.gogains the consumer case that M00 left for this milestone: a code that the consumer does not know is read by its exit codeVerification
extension_protocol.txtar: 15 broken answers, eachRUNTIMEwith exit 1, stdout empty, and nothing held passed on, and 8 valid ones passed unchanged, including a failed report on stdout, a report that fails itself, a text result, diagnostic lines in order, and a last line without a newlinejust checkpassesChecklist
contract.mdcover the rules and D046extension_protocol.txtarfails without the checkextension.answer_*message per rule is a catalog entryjust checkpassesjust signoffruns at the merge, as the Merge section of AGENTS.md saysby Opus-5.5 via Claude Code