Repository navigation
Answer each approval and question once, and show Codex questions as cards (CF-3) - #293
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Code coverage overviewLanguages: TypeScript TypeScript / code-coverage-agent
View coverage of the 10 most impacted files.
ℹ️ Calculations represent line coverage. Results may change as calculations are updated. Updated |
|
Review from the #273 tracker session, at
One documentation nuance. For the owners: this PR and #295 (CF-4) both edit |
|
CF-3 reconciliation at Using the existing
The fixture receives zero native answers, because A deterministic regression reproduced this locally. The accepted answer needs an actual backend handoff outcome; withdrawal or disconnect before that handoff must leave a truthful withdrawn/uncertain receipt instead of an ordinary answered card. Please retain the no-resend behavior and keep sensitive answers out of the receipt. This is the unresolved #276 acceptance criterion for withdrawal during answer submission. No production changes were made to the owning branch. The regression and its failing log are preserved in the separate |
Opening a tab (⌘⇧B) focuses its address bar twice: once when the tab becomes active, and again in an animation frame that newTab queues for when the panel was not yet visible. Chromium can hold frames back for an inactive or busy window. The late focus then landed after the person, or a test, had already moved on, and took the caret out of the composer mid-typing. That failed CI on #293: store-desktop.spec.ts's browser-tools recovery case filled the composer just as the late frame ran. The text went into the address bar and the composer stayed empty (job 117782462586). The same case failed on #294's first run. The late focus now applies only if focus has not moved since the tab opened. The new workspace.spec.ts case holds animation frames, moves to the composer, releases the frames and types. It failed first: the composer lost focus when the frame ran. Coven-Harness: Claude Code / claude-opus-5-5
shared/human-requests.ts: approvals and native questions as one versioned contract. A request is bound to thread, turn, attempt, account, runtime and native request id plus a digest of the exact action; it accepts one local answer, and an unknown id, a wrong identity, a changed action, a withdrawn request or a second answer authorises nothing. Stop withdraws pending requests; one whose answer was being sent becomes uncertain, never resolved. Codex's experimental item/tool/requestUserInput (codex-cli 0.163.0) maps to typed questions, answers are validated against them, and secret answers are hidden from anything shown, saved or exported. Not wired in yet: that consumes #275's interfaces once #286 lands. Refs #276 Coven-Harness: Claude Code / claude-opus-5-5
…stale cards The runner keeps the turn's approvals and questions in the human-request broker. The first answer is taken; every other one is refused with a reason (already resolved, withdrawn, unknown, invalid) that thread:answer now returns and the phone receives as a 409. Codex item/tool/requestUserInput (codex-cli 0.163.0, experimental) becomes a question card, answered through thread:answer-question. Answers are checked against the questions before anything reaches Codex. A secret answer goes to the CLI only and is saved as "(hidden)". Stop sends an error reply, never an empty answer. When serverRequest/resolved arrives for a request still open, Codex settled it, so the card closes as withdrawn and no answer is sent. Approvals now carry the CLI's own request id (Codex JSON-RPC id, Claude request_id). Cards a dead process left open close as ended when their thread loads, saved and emitted. Phones see a question as a notice to answer on the Mac. Part of #276. Coven-Harness: Claude Code / claude-opus-5-5
Options are radio buttons, with Other when the question takes free text. A free-text question gets a text field, and a secret one a password field. A refused answer says why on the card. An answered card lists the answers, with a secret shown as (hidden). A closed card says why, in the approval card's words. The turn header reads "Waiting for your answer" while a question waits. An answered or closed question folds into the turn's work; an open one never does. The e2e drives a fixture codex-cli 0.163.0 app-server through the real UI. It covers an incomplete answer refused in place, one reply carrying the answers, a refused second answer, Stop giving an error reply, and no secret anywhere under MODEX_HOME/app. Part of #276. Coven-Harness: Claude Code / claude-opus-5-5
docs/human-requests.md covers the broker's exported signatures, its states and refusals, the runner's binding and withdrawal rules, the Codex 0.163.0 and Claude 2.1.302 mappings, the clients, how secrets are kept, the tests, and what is left for CF-6 and CF-7. Part of #276. Coven-Harness: Claude Code / claude-opus-5-5
Opening a tab (⌘⇧B) focuses its address bar twice: once when the tab becomes active, and again in an animation frame that newTab queues for when the panel was not yet visible. Chromium can hold frames back for an inactive or busy window. The late focus then landed after the person, or a test, had already moved on, and took the caret out of the composer mid-typing. That failed CI on #293: store-desktop.spec.ts's browser-tools recovery case filled the composer just as the late frame ran. The text went into the address bar and the composer stayed empty (job 117782462586). The same case failed on #294's first run. The late focus now applies only if focus has not moved since the tab opened. The new workspace.spec.ts case holds animation frames, moves to the composer, releases the frames and types. It failed first: the composer lost focus when the frame ran. Coven-Harness: Claude Code / claude-opus-5-5
|
CI on |
|
From the docs steward (#290). This is coordination, not a review. #283 merged as I'm leaving that line alone on |
#283 merged as a4039b2, but the CF-1 block's Still open line still listed "the Markdown parser (#283)". #293 rewrote that line before #283 landed and kept the item, so it stayed on main after #293 merged (57e7607). Name what CF-4 still has open instead: #277's checkpoint lists reference-viewport screenshots and a keyboard and reduced-motion review of the Markdown elements; human VoiceOver is already in the list. Coven-Harness: Claude Code / claude-opus-5-5
… slice Coven-Harness: Claude Code / claude-opus-5-5
… from Still open (#306) * Record #185's downgrades in the approval rules spec The spec's Known limits said commands are clipped before judgment "without a truncation downgrade", and its rule section listed only the destructive and escalation downgrades. Since #185 (2026-10-12), an allow also asks when the full command line chains, redirects or substitutes commands, or when the digest clipped text Jev needed (approvals/gate.ts:155-158, digest.ts:103-111). Add a dated progress note under the enablement list: #185 closed the clipped-command false allow, the quoted-command one is open and the corpus has not been run live since, so item 1 is unmet. The note names the next step. The enablement criteria themselves are unchanged. Coven-Harness: Claude Code / claude-opus-5-5 * Drop the merged Markdown parser from status.md's Still open list #283 merged as a4039b2, but the CF-1 block's Still open line still listed "the Markdown parser (#283)". #293 rewrote that line before #283 landed and kept the item, so it stayed on main after #293 merged (57e7607). Name what CF-4 still has open instead: #277's checkpoint lists reference-viewport screenshots and a keyboard and reduced-motion review of the Markdown elements; human VoiceOver is already in the list. Coven-Harness: Claude Code / claude-opus-5-5
CF-2 (#286), CF-3 (#293), CF-4's Markdown slice (#283), CF-6's request half (#308) and CF-7's clarifications (#312) are on main, with their merge commits. The candidate note says the fixture rows now run on main, and no candidate is pinned while the live-provider and human gates stay open. Refs #281 Coven-Harness: Claude Code / claude-opus-5-5
…nts at once, reconnect, a clarifying question (CF-8) (#313) * Add the request variants to the fidelity path Four cases in e2e/conversation-fidelity.spec.ts, through the real app: - A native withdrawal: the Claude fixture takes its own request back (control_cancel_request). The card closes as withdrawn, no answer reaches the CLI, a late answer is refused, and the file is unchanged. - The desktop and the phone answer at once, over the bridge and the companion's HTTPS. Exactly one is accepted, the CLI reads one decision, the card names who gave it, and the file matches the winner. - With the journal on, a phone that loaded the open card reconnects after the desktop's decision. Its delta shows the card answered by the desktop and sent, its late answer is a 409, and every count stays at one. - A clarifying question inside the path, from a codex-cli 0.163.0-shaped fixture: answered on its card, heard once, followed by a real edit and check, saved to Notes, and inert after a restart that re-runs nothing. The fixture now counts every decision the CLI reads, so the earlier cases assert that too. The golden path is marked slow: since #301 it also takes 18 reference captures and relaunches, and it ran past 90 s on a Mac at load average 100. These cases found the companion's 404 for threads started on the Mac, fixed in the CF-6 branch. Refs #281 Coven-Harness: Claude Code / claude-opus-5-5 * Record the request variants in the acceptance receipt The matrix rows for a clarifying question, a native withdrawal, simultaneous answers and a reconnect after a decision move from open to verified with a fixture, with what each case asserts. The defects list adds the companion's 404 for threads started on the Mac. The fidelity summary gains rows for questions and approvals. Refs #281 Coven-Harness: Claude Code / claude-opus-5-5 * Record CF-8's request variants in status Refs #281 Coven-Harness: Claude Code / claude-opus-5-5 * Record the landed children in the acceptance receipt CF-2 (#286), CF-3 (#293), CF-4's Markdown slice (#283), CF-6's request half (#308) and CF-7's clarifications (#312) are on main, with their merge commits. The candidate note says the fixture rows now run on main, and no candidate is pinned while the live-provider and human gates stay open. Refs #281 Coven-Harness: Claude Code / claude-opus-5-5
Part of #276 (CF-3 of tracker #273).
What changes
One answer per request. The runner keeps the turn's approvals and questions in the pure broker from
shared/human-requests.ts. The first answer is accepted. Every other one gets an explicit reason:already-resolved,withdrawn,unknownorinvalid.thread:answernow returns that verdict, and the phone gets a 409.request_idandtool_use_id.Codex questions.
item/tool/requestUserInput(codex-cli 0.163.0, experimental) used to be declined with-32601. It is now a question card.thread:answer-questionand are validated before anything reaches Codex. Codex receives{ answers: { id: { answers } } }.-32602.Secrets. A secret answer is written to the CLI's stdin only. Saved items, item events, the journal and the phone see
(hidden).Withdrawal.
-32000), never an empty answer.serverRequest/resolvedfor a request still open means Codex settled it itself. The card closes as withdrawn, and Modex sends nothing.endedwhen their thread loads, and the change is saved and emitted.Clients.
Contract, mappings and limits:
docs/human-requests.md.Tests (red first)
test/human-requests.test.ts, for the broker: 6 of 6 pass.test/human-requests-runner.test.ts, for the runner and the Codex backend: 6 of 6 pass. Each was watched failing first:serverRequest/resolvedwithdrawing with no reply. I wrote this handler before its test, so I disabled it to watch the test fail, then restored it;test/companion.test.ts, new case: the question fallback text, no answers sent to the phone, and the runner's refusal as a 409.test/turn-layout.test.ts, new case: an open question never folds.e2e/human-requests.spec.tsruns a fixture codex-cli 0.163.0 app-server through the real app. It failed first with no card, then failed on the header label. The fixture also answers Modex's title-naming turn, which runs on the same app-server. It now covers:MODEX_HOME/app.Checks run locally
macOS on Apple Silicon, Node v24.18.1, pnpm 10.34.5:
pnpm build(all apps, including store-desktop): passed.pnpm --filter @modex/store-desktop test: 16 of 16 pass.apps/desktoppnpm test: 1,554 passed and 16 skipped. One CF-2 test,claude-lifecycle"an unconfirmed stop keeps the worktree…", hit its 6 s timeout at a load average above 100. Rerun alone, its file passed 23 of 23, and the.mjssuites passed 21 of 21.human-requests,approvals,approval-policy,claude-lifecycle,app,typed-turns,companion,space-fit,conversation-evidence,store-demoandstore-desktop: 58 of 58 pass.Not in this PR
requestUserInputcapture. The question path is proven on the schema-shaped fixture only.Coven-Harness: Claude Code / claude-opus-5-5