Repository navigation
Coordinators and waits - #515
Conversation
Quest-Claim: 55e0360b005f0226
Add `quest setup`, which sets Claude Code's BASH_MAX_TIMEOUT_MS to 55 minutes in the user's settings so a foreground wait outlasts the 10-minute default without polling. The shared rules now name the polling shapes to avoid, batch independent reads into one turn, cap a sub-agent's report at what its caller acts on, and have coordinators lean on compaction with durable state in the forge and the quest tree. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 19 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
kixelated
left a comment
There was a problem hiding this comment.
Automated review by review (OpenAI)
Reviewed head: afb31de
Findings: No actionable defects found. Reviewed all nine changed files, the CLI dispatch and setup implementation, settings-preservation/error/idempotence tests, and coordinator instructions. The setup command correctly bypasses repository healing; the documented overwrite of an existing timeout is deliberate.
Direction: Keep the current approach and complete the required landing checks.
Verification limits: GitHub-only static review; I did not execute tests or validate the timeout in a live Claude Code session. The PR reports local check/test passes. GitHub Check and Queue runs were skipped; Release succeeded, which is not a substitute for the merge-group checks.
(Written by unknown OpenAI model)

Finishes Coordinators and waits from the token waste epic.
Summary
The audit measured polling at 6.8% of Claude Code cost (
until grep ... sleeploops, sleeps, empty background waits), serial reads at 35% of turn cost, and a/quest-completecoordinator that grew to 966k context on 374 child reports of up to 37k characters.quest setup(new): setsenv.BASH_MAX_TIMEOUT_MS=3300000in the user's Claude Code settings ($CLAUDE_CONFIG_DIR/settings.json, or~/.claude/settings.json), keeping every other setting. A foreground wait can then block 55 minutes, just under the 1h cache TTL, instead of hitting the 10-minute default, so no session depends on a shell profile. Malformed settings fail before anything is written. Safe to rerun; prints each change. Documented in README and SETUP.md.assets/CONTEXT.mdWorkspace: every turn re-sends the context, so batch independent reads, searches, and checks into one turn; name the banned wait shapes once (sleep,until/whilere-check loops, timeouts far below the tool's limit, repeated status checks or output reads of a running task); a sub-agent's final report holds only what its caller acts on (PR URL, state, head, decisions with recommendations), with details in the PR body; a long-running coordinator lets compaction bound its context, keeps durable state in the forge and the quest tree, and re-reads a PR's state before acting on it./quest-complete: a sub-agent's brief names the PR's standing pick and its report repeats it, so a/quest-mergepick outlasts compaction.Public API
New command
quest setup. No breaking change; no wire impact.Choices made without asking
quest setupoverwrites a different existingBASH_MAX_TIMEOUT_MSand prints the old value, rather than keeping a custom one: a value above the TTL or far below it defeats the setting's purpose, and the user ran the command to get it.quest setuponly touches Claude Code. Codex has no equivalent cap on a command's timeout in its config.quest setuplives insrc/cli/setup.tsbesideinit; Rules load once adds itsSessionStarthook install to the same command, so expect a conflict there resolved by merging.assets/CONTEXT.mdnext to the existing coordinator line rather than in each of/quest-complete,/quest-spawn, and/quest-afk, so it is said once./quest-spawnkeeps all its state in claim PRs already, so it needed no change.Validation
quest gate just check: pass.quest gate just test: pass (30 files, 1090 tests).test/setup.test.ts: missing file and directory, idempotence, keeping other settings, replacing a different cap, refusing malformed JSON, a non-object, or a non-objectenvwithout writing.Caused by
None: new work from the token waste audit, not a fix of an earlier PR.
Models
Size: M
Implementer: Claude Code, claude-opus-5-5, high effort
Review
Rewritten by
quest reviewafter each round.01a1adde-1f52-7d92-95b3-fb41d99330a5, round 1No actionable defects were found in the specified diff; just check and just test were attempted but blocked by the read-only sandbox when the gate tried to write admission records.🤖 Generated with Claude Code
(Written by Claude Opus 5.5 with high effort)