diff --git a/quest/m0/README.md b/quest/m0/README.md index d57b0620..0b670c65 100644 --- a/quest/m0/README.md +++ b/quest/m0/README.md @@ -53,7 +53,9 @@ ownership-manifest design: line, and Claude hook entries in `.claude/settings.json` that only call a `quest` subcommand. Upgrading never rewrites repository files. (Amended 2026-10-26 (user), replacing "Nothing is vendored", so `quest init` can - install the agent lifecycle hooks.) + install the agent lifecycle hooks. Amended 2026-11-01 (user, /quest-plan): + `quest init` also rewrites a Quest-written stub nobody edited when its + text is out of date; see [Skill stub cleanup](/quest/m0/skill-stubs.md).) - The repository's own tool manager pins the version: mise (release binaries) or a nix flake input (any rev, built from source). Quest ships no launcher and no pin file; an install outside either is simply unpinned. @@ -71,6 +73,8 @@ ownership-manifest design: - [Drop emptied Required headings](/quest/m0/required-heading.md) - a clean driver merge that empties a `Required` list passes `quest check` - [Current conflict reports](/quest/m0/land-conflicts-refresh.md) - a queued PR's conflict report updates when the queue ahead of it changes - [Land checks at gate priority](/quest/m0/land-priority-sandbox.md) - `quest land serve` passes `QUEST_GATE_PRIORITY` to its sandbox +- [Squash mismatch comment](/quest/m0/land-squash-mismatch.md) - a post-squash `tree_mismatch` posts a CRITICAL comment on the merged PR +- [Current landing status](/quest/m0/status-landing.md) - `quest status` drops a stale `landing-stopped` line and ignores superseded cancelled checks - [Kix decision UI](/quest/m0/kix/README.md) - planning and implementation through prompts and summaries, run on the maintainer's own runners - [Codex cloud off](/quest/m0/codex-cloud-off.md) - automatic Codex cloud reviews stop once no open PR relies on them - [Review handles expired and environment logins](/quest/m0/review-login.md) - `quest review` says to log in again instead of failing with a 401, and reviews with credentials from the environment @@ -81,4 +85,12 @@ ownership-manifest design: - [Gate bench](/quest/m0/gate-bench.md) - measure headroom admission on an idle host - [Gate admission on CI](/quest/m0/gate-ci-admission.md) - gated commands admit on loaded hosted runners like arm64 macOS - [Agent workflow helpers](/quest/m0/helpers/README.md) - CLI commands for CI waits, PR status, claims, quest moves, and serialized merges +- [Review the branch's own change](/quest/m0/review-merge-base.md) - `quest review` diffs against the merge base and accepts a detached `HEAD` +- [Skill stub cleanup](/quest/m0/skill-stubs.md) - stray skill copies deleted, and `quest init` refreshes unedited outdated stubs +- [Merge driver upkeep](/quest/m0/merge-driver-upkeep.md) - local merges drop links to finished quests, old drivers upgrade, and `quest-pinned` stays current +- [Worktree hooks here](/quest/m0/worktree-hooks.md) - `quest` reaches Claude Code's hooks and the merge driver in this repository, then `quest init` installs the hooks +- [Other worktree routes](/quest/m0/worktree-routes.md) - live-check PR worktrees, agent view, remote-control, and workflow agents against the hooks +- [Spotlight off in macOS CI](/quest/m0/ci-spotlight.md) - this repository's macOS jobs turn off Spotlight indexing first +- [Review through a gateway](/quest/m0/review-gateway.md) - `quest review` keeps gateway, cloud-provider, and Codex connection variables +- [opencode SDK 2.x](/quest/m0/opencode-sdk.md) - the runner moves to `@opencode/sdk` 2.x so the nixpkgs bump lands - [Review harness check](/quest/m0/review-harness.md) - recurring each milestone: newest pinned review models, and the live sandbox test passes diff --git a/quest/m0/ci-spotlight.md b/quest/m0/ci-spotlight.md new file mode 100644 index 00000000..950cd52d --- /dev/null +++ b/quest/m0/ci-spotlight.md @@ -0,0 +1,23 @@ +# [XS] Turn Spotlight off in this repository's macOS CI jobs + +## Goal + +Every macOS job in this repository's workflows runs `sudo mdutil -a -i off` +as its first step, so Spotlight's first full index of the fresh VM no +longer competes with the job. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [XS], m0, from +[moq-dev/quest#342](https://github.com/moq-dev/quest/pull/342)'s suggested +follow-ups. + +- #342's diagnostic run held `macos-14`'s load at about 4× its 3 CPUs for + the whole sample while Spotlight indexed, dropping below 1 within minutes + once it was off. The gate already admits a lone command on such a host, + so this is about job time, not admission. +- The jobs: Check's `lifecycle` on `macos-14` + (`.github/workflows/check.yml`), Release's `macos` jobs + (`release.yml`), and Install check's macOS jobs (`install-check.yml`). + Compare a job's time before and after. diff --git a/quest/m0/host-land/README.md b/quest/m0/host-land/README.md index aafc7dcb..f2d51578 100644 --- a/quest/m0/host-land/README.md +++ b/quest/m0/host-land/README.md @@ -81,9 +81,10 @@ can hand off instead. - No GitHub Actions in landing (user, 2026-10-30): the daemon replaces the Land workflow and the host's `quest-land` Actions runner, and ejection comments carry the failing log's tail. -- This epic ranks first in m0. It replaces the hook-started kix fixer that - [moq-dev/quest#276](https://github.com/moq-dev/quest/pull/276) proposes - (`kix/eject-fix`). +- This epic ranks first in m0. It replaces the hook-started kix fixer + (`kix/eject-fix`) that + [moq-dev/quest#276](https://github.com/moq-dev/quest/pull/276) proposed; + #276 was closed as superseded on 2026-11-01. - The epic finishes with an end-to-end run on moq-dev/quest: a batch with one PR that fails a check, one that conflicts with the base, and one healthy PR. The healthy PR lands after the requeue, the mechanical one lands after @@ -98,4 +99,5 @@ can hand off instead. - [Gate host](/quest/m0/host-land/host.md) - kixelated/nixos runs the daemon as its own user, checks in nspawn containers, and retires the Actions runner - [Fixer proxy access](/quest/m0/host-land/fixer.md) - connect the nixos fixer container to CLIProxyAPI with the gate client key and maintainer login +- [Fixer TLS](/quest/m0/host-land/fixer-tls.md) - the fixer's container trusts public certificates, so workerd and the Worker tests run there - [Daemon restart keeps its check](/quest/m0/host-land/reattach.md) - a deploy no longer reruns the batch it interrupted diff --git a/quest/m0/host-land/fixer-tls.md b/quest/m0/host-land/fixer-tls.md new file mode 100644 index 00000000..2095801d --- /dev/null +++ b/quest/m0/host-land/fixer-tls.md @@ -0,0 +1,29 @@ +# [S] The fixer's container trusts public TLS certificates + +## Goal + +The land fixer's nspawn container validates TLS like a normal host, so +workerd and the Cloudflare Worker tests run there. A fixer job on +moq-dev/quest builds and tests the Worker (`cd cloudflare && bun run test`) +without workerd's "TLS peer's certificate is not trusted; reason = unable to +get local issuer certificate". Check it by re-running the fixer on a PR that +touches the Worker, or by running the Worker tests by hand in a fixer +container. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [S], in this epic. + +- The fixer handed back + [moq-dev/quest#331](https://github.com/moq-dev/quest/pull/331) for this + ([handback](https://github.com/moq-dev/quest/pull/331#issuecomment-6563898322)): + its resolution of `test/land.test.ts` was right, but it could not run the + Worker suite, so it could not report the fix as tested. +- The fix lands in [kixelated/nixos](https://github.com/kixelated/nixos), in + `modules/quest-land.nix`, which builds the fixer container. A likely + cause is a missing CA bundle at the standard path, or + `SSL_CERT_FILE`/`NIX_SSL_CERT_FILE` not reaching the fixer's dev shell. + Confirm the cause before changing anything. +- Check the land check containers for the same gap, since they run the same + suites. diff --git a/quest/m0/kix/README.md b/quest/m0/kix/README.md index 9448d22b..0045142d 100644 --- a/quest/m0/kix/README.md +++ b/quest/m0/kix/README.md @@ -141,3 +141,4 @@ fixes what it finds: - [Job sandbox](/quest/m0/kix/sandbox/README.md) - head approval for kix-pushed heads, and opencode sandboxed - [Web execution](/quest/m0/kix/execution.md) - spawn and iterate through the UI, ending in contribution PRs - [Land review](/quest/m0/kix/land-review.md) - kix lands only heads with a review that counts on that exact head +- [Runner review checks](/quest/m0/kix/review-check.md) - runners publish the App's `quest review` check, so their heads land without a human approval diff --git a/quest/m0/kix/review-check.md b/quest/m0/kix/review-check.md new file mode 100644 index 00000000..41de425d --- /dev/null +++ b/quest/m0/kix/review-check.md @@ -0,0 +1,32 @@ +# [M] Runners publish the App's quest review check + +## Goal + +After a runner publishes a head, it runs `quest review` on that head with +the other vendor's account, outside the agent's sandbox, and kix writes the +result as the App's `quest review` check run on that commit. A head a +runner pushed then lands through kix's land gate without a human approval, +once that check passes. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [M], m0, from +[moq-dev/quest#351](https://github.com/moq-dev/quest/pull/351)'s suggested +follow-ups. + +- #351's gate (`cloudflare/src/github/review.ts`) already counts a + completed, successful `quest review` check run by this App on the exact + head. Nothing writes one yet, and the author's `## Review` record never + counts on a commit an App committed, so every runner head needs a person's + approval today. +- The runner process, not the agent, runs the review, so the agent cannot + fake it. It sends the result to kix over a new runner protocol message. +- The App needs `checks: write`, which existing installations must accept; + add the operator step to `cloudflare/GITHUB.md`. +- Choose which jobs run it, such as iterate and merge jobs after they + publish. + +## Required + +- [Land review](/quest/m0/kix/land-review.md) - the gate that counts the App's check diff --git a/quest/m0/land-fixer/protected-commit.md b/quest/m0/land-fixer/protected-commit.md index 52adf8e6..729b1fce 100644 --- a/quest/m0/land-fixer/protected-commit.md +++ b/quest/m0/land-fixer/protected-commit.md @@ -3,7 +3,9 @@ ## Goal When `validateFix` rejects a fixer result because it edits a protected path -(`.github/`, `flake.nix`, `nix/`, justfiles, gitlinks) beyond what the base +(`.github/`, `nix/`, `flake.nix`, `flake.lock`, `shell.nix`, `default.nix`, +`.envrc`, `.gitmodules`, and gitlinks, as `validateFix` in +`src/cli/land-fixer.ts` lists them) beyond what the base merge carries, the handback carries that result as a ready commit, the same form as a fork push GitHub refuses ([moq-dev/quest#358](https://github.com/moq-dev/quest/pull/358)). diff --git a/quest/m0/land-squash-mismatch.md b/quest/m0/land-squash-mismatch.md new file mode 100644 index 00000000..ba351163 --- /dev/null +++ b/quest/m0/land-squash-mismatch.md @@ -0,0 +1,24 @@ +# [XS] A post-squash tree mismatch comments on the merged PR + +## Goal + +When GitHub's squash of a landed PR has a different tree from the one the +gate tested, `quest land serve` posts a CRITICAL comment on that merged PR, +naming the squash commit, both trees, and what happened to the rest of the +batch. Today the mismatch reaches only the host's log and warning line, so +nobody reading the PR learns that `main` holds an untested tree. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [XS], m0. + +- Raised as a follow-up in + [moq-dev/quest#321](https://github.com/moq-dev/quest/pull/321), which made + a post-squash `tree_mismatch` keep the PR merged and the rest of the batch + queued. The detail is built in `src/cli/land-serve.ts` (`CRITICAL: GitHub + squash #N at has tree ...`), then only logged and warned. +- Post it through the daemon's existing comment path, with its marker and + deduplication, so a restarted daemon doesn't post it twice. +- Extend the post-squash tree-mismatch test in `test/land.test.ts` to expect + the comment. diff --git a/quest/m0/merge-driver-upkeep.md b/quest/m0/merge-driver-upkeep.md new file mode 100644 index 00000000..5440803c --- /dev/null +++ b/quest/m0/merge-driver-upkeep.md @@ -0,0 +1,38 @@ +# [S] Keep local merges and the merge driver current + +## Goal + +A local merge of the base into a quest branch needs no hand edits for +links to quests the base finished: a command, such as `quest check --fix`, +drops those list links as `quest land` does. Clones whose +`merge.quest.driver` an older quest version registered get the current +driver, while a custom driver stays untouched. The dev shell's +`quest-pinned` flake input stays current, so its merge driver has the +latest fixes. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [S], m0. + +- Finished links: + [moq-dev/quest#353](https://github.com/moq-dev/quest/pull/353) makes + `quest land` drop `Required`, `Related`, and `Closes` links to quests + the base deleted since the PR's merge base, using core `remove()`. Apply + the same edit in a checkout after merging the base, for example with + `quest check --fix` or `quest resolve --finish `, and point + the guide's merge line at it. Links in prose stay for a person to fix. +- Driver upgrades: `heal` in `src/cli/setup.ts` sets + `merge.quest.driver` only when none is configured, so clones keep the + driver an older quest wrote and miss + [moq-dev/quest#344](https://github.com/moq-dev/quest/pull/344)'s fallback + warning. Recognize earlier quest-generated driver strings and replace them + with the current `DRIVER`. +- The pin: [moq-dev/quest#344](https://github.com/moq-dev/quest/pull/344) + added the `quest-pinned` input, which only a manual `nix flake update + quest-pinned` bumps. Pick how it stays current, such as Dependabot's nix + updates, a step in the release checklist, or a recurring quest, and do it. + +## Related + +- [Merge queue siblings](/quest/m0/helpers/queue-siblings.md) - the landing-time drop this quest brings to local merges diff --git a/quest/m0/opencode-sdk.md b/quest/m0/opencode-sdk.md new file mode 100644 index 00000000..dde4d0ae --- /dev/null +++ b/quest/m0/opencode-sdk.md @@ -0,0 +1,29 @@ +# [M] The runner's opencode adapter uses @opencode/sdk 2.x + +## Goal + +The runner's opencode adapter (`src/runner/opencode.ts`) drives opencode +2.x through `@opencode/sdk` 2.x, matching the opencode that the bumped +nixpkgs ships, so Dependabot's nixpkgs bump +[moq-dev/quest#281](https://github.com/moq-dev/quest/pull/281) can land. +The flake's `opencode-sdk` check passes, and the runner's opencode tests +pass against the new SDK. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [M], m0. + +- nixpkgs now ships opencode 2.0.32. `package.json` pins + `@opencode-ai/sdk` 1.19.0, and `flake.nix`'s `opencode-sdk` check fails + unless that pin equals `pkgs.opencode.version`, so #281 cannot land + alone. Move to the renamed `@opencode/sdk` at the version nixpkgs ships, + adapt the adapter to its 2.x API, and point the flake's check at the new + package name. +- Land the nixpkgs bump in the same PR, or merge #281 into it. +- [moq-dev/quest#280](https://github.com/moq-dev/quest/pull/280) adds a + Dependabot ignore for `@opencode-ai/sdk`, since the SDK must move with + nixpkgs' opencode. That ignore must also cover `@opencode/sdk`. +- Run the runner's live opencode checks that the + [Kix decision UI](/quest/m0/kix/README.md) rehearsal lists, if a runner is + available. diff --git a/quest/m0/review-gateway.md b/quest/m0/review-gateway.md new file mode 100644 index 00000000..3a58a836 --- /dev/null +++ b/quest/m0/review-gateway.md @@ -0,0 +1,33 @@ +# [S] quest review routes through a gateway or cloud provider + +## Goal + +`quest review` works when the reviewer CLI reaches its model through a +gateway such as CLIProxyAPI, or through a cloud provider. The reviewer +keeps `ANTHROPIC_BASE_URL` with its token, `ANTHROPIC_CUSTOM_HEADERS`, +Claude Code's Bedrock, Vertex, and Foundry switches, and Codex's +`CODEX_ACCESS_TOKEN` and `CODEX_CA_CERTIFICATE`, instead of having them +stripped and being reported as logged out. Variables that would change the +reviewer's plugins, permissions, or configuration are still stripped. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [S], m0: pass these through instead of blocking them. + +- [moq-dev/quest#339](https://github.com/moq-dev/quest/pull/339) lets a + reviewer keep the credential its own CLI reads from the environment, and + passes `CODEX_API_KEY` when `codex login status` fails. It still strips the + variables that send requests to a gateway or another provider, and blocks + credentials while one is set, as the review-login quest's 2026-10-30 + decision asked. That decision kept stripping variables that redirect + billing. This one supersedes it for the gateway and provider variables in + the Goal, because the maintainer routes reviews through them on purpose. +- Reuse the gateway and cloud-routing tests from closed + [moq-dev/quest#316](https://github.com/moq-dev/quest/pull/316), whose + branch `fix/review-provider-environment` + ([79fb7c4](https://github.com/moq-dev/quest/commit/79fb7c4cd45976184c5adc7adc286283b206231c)) + is still on GitHub. +- Keep the managed agents' (`quest agent`) account isolation as it is. If a + credential is still stripped on purpose, the error names the variable + instead of saying "not logged in". diff --git a/quest/m0/review-harness.md b/quest/m0/review-harness.md index 7caeff92..ba4ca319 100644 --- a/quest/m0/review-harness.md +++ b/quest/m0/review-harness.md @@ -15,6 +15,19 @@ Decided 2026-10-28 (user, /quest-plan of the follow-ups from [moq-dev/quest#271] accept the new ids. - Run the live sandbox test, `just review-sandbox`, with the CLIs installed at the time, and plan a quest for any failure. +- Extend the live sandbox test (decided 2026-11-01, user, /quest-plan of + [moq-dev/quest#341](https://github.com/moq-dev/quest/pull/341)'s + suggested follow-ups): + - macOS keychain logins: both CLIs can keep their login in the keychain, + where there is no file to copy into the disposable config home, so the + test runs only on Linux today. + - More of Claude Code's project settings as plants: + `.claude/settings.local.json`, `statusLine`, `apiKeyHelper`, `env`, and + permission rules. + - Codex reads a linked worktree's hooks from the main checkout's + `.codex/hooks.json`. Check whether the land fixer + (`src/cli/land-fix.ts`) or headless agents (`quest agent`) rely on + worktree-local Codex hooks. - This quest recurs. The PR that finishes this run creates `/quest/m1/review-harness.md` with this Goal, listed in m1's `Required`, and `Required: /quest/m0/README.md`, so the next run becomes ready when m0 diff --git a/quest/m0/review-merge-base.md b/quest/m0/review-merge-base.md new file mode 100644 index 00000000..6bd1eee3 --- /dev/null +++ b/quest/m0/review-merge-base.md @@ -0,0 +1,29 @@ +# [S] quest review covers only the branch's own change, on any checkout + +## Goal + +`quest review` reviews the change between the base's merge base and `HEAD` +(`origin/main...HEAD`) with both reviewers. A branch that is behind its +base gets no findings on the base's newer code, which reads as reverted in a +two-dot diff. It also reviews a detached `HEAD`, since a merge session +can't check out a branch another worktree already holds. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [S], m0. + +- In [moq-dev/quest#337](https://github.com/moq-dev/quest/pull/337), round 1 + reported two findings on code that main had gained after the branch's + merge base, which the branch did not touch. Claude's turn already asks for + `...HEAD` (`src/cli/review.ts`), but Codex's `codex exec review + --base ` reviewed main's newer code. Give each reviewer the merge + base itself, or whatever form makes both review only the branch's change, + and test it with a branch behind its base. +- [moq-dev/quest#348](https://github.com/moq-dev/quest/pull/348)'s merge + fixes were reviewed from a differently named local branch, because the PR's + branch was checked out in another worktree. `review()` refuses a detached + `HEAD` ("check out the branch to review") and keys the session state by + the branch name. Accept a detached `HEAD`, and key its session so that + later rounds on the same work resume it, for example by the PR or by a + name passed on the command line. diff --git a/quest/m0/skill-stubs.md b/quest/m0/skill-stubs.md new file mode 100644 index 00000000..652cc233 --- /dev/null +++ b/quest/m0/skill-stubs.md @@ -0,0 +1,34 @@ +# [S] Clean up stray skills and refresh outdated stubs + +## Goal + +The repository ships no stale skill text, and `quest init` brings a +repository's skill stubs up to date. `assets/skills/quest-merge.md` is +deleted, and `assets/skills/quest-close.md` is deleted unless something +still needs it. `quest init` rewrites a Quest-written stub of a current +skill that nobody edited but whose description or setup link is out of +date. A stub someone edited stays as it is. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [S], m0, including the stub refresh. + +- `assets/skills/quest-merge.md` is an old copy of the merge skill, added in + [moq-dev/quest#335](https://github.com/moq-dev/quest/pull/335). It still + tells agents to wait for an automated review, and nothing in + `src/cli/skills.ts` imports it. `assets/skills/quest-close.md` ("Abandon a + quest or PR") is also not imported; `assets/skills/delete.md` replaced it. + Check for any other reference before deleting either. +- The refresh was suggested in + [moq-dev/quest#337](https://github.com/moq-dev/quest/pull/337), which + recognizes a stub of any version by its shape (`STUB` in + `src/cli/setup.ts`). Rewrite only stubs that match that shape exactly, so + an edited stub or a user's own `quest-` skill is never touched. +- The refresh amends m0's "Upgrading never rewrites repository files"; the + [milestone's Plan](/quest/m0/README.md) records it. `docs/getting-started.md` + says "existing stubs stay as they are"; update it. + +## Related + +- [Stale skill stubs](/quest/m0/init-prune.md) - removes stubs of retired skills; this quest refreshes those of current ones diff --git a/quest/m2/status-landing.md b/quest/m0/status-landing.md similarity index 70% rename from quest/m2/status-landing.md rename to quest/m0/status-landing.md index 8a2a6405..8155fc6e 100644 --- a/quest/m2/status-landing.md +++ b/quest/m0/status-landing.md @@ -20,3 +20,9 @@ Decided 2026-10-31 (user, /quest-plan of the follow-ups from a moq-dev/moq A cancelled run and a newer passing run of the same check both count, so the check still shows as failing. Count only the newest run of each check name. + +Moved from m2 to m0 on 2026-11-01 (user, /quest-plan of the follow-ups from +the 2026-11-01 `/quest-complete` sessions): ✅ m0, beside the land quests · +leave it in m2. The moq-dev land gate and the agents picking merges read +`quest status` every day, so a stale `landing-stopped` line or a superseded +cancelled check sends them after PRs that are already queued and passing. diff --git a/quest/m0/worktree-hooks.md b/quest/m0/worktree-hooks.md new file mode 100644 index 00000000..0dd9d2eb --- /dev/null +++ b/quest/m0/worktree-hooks.md @@ -0,0 +1,29 @@ +# [S] This repository installs its own worktree hooks + +## Goal + +Claude Code sessions in moq-dev/quest reclaim their subagents' checkouts +through `quest worktree hook`, as `quest init` sets up in other +repositories. `quest` is reliably available to Claude Code's hook +environment here, and on `PATH` for the merge driver, without running a PR +head's code. `quest init` then installs the hooks in this repository's +`.claude/settings.json`. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [S], m0. Sources: +[moq-dev/quest#350](https://github.com/moq-dev/quest/pull/350)'s decision 1a +and [moq-dev/quest#359](https://github.com/moq-dev/quest/pull/359). + +- [moq-dev/quest#350](https://github.com/moq-dev/quest/pull/350) shipped the + hooks but, by its decision 1a, didn't install them here: Claude Code runs + hooks in its own environment, not the direnv dev shell, and the merge + driver also needs `quest` on `PATH`. This repository's 65 leaked + worktrees (8.2 GB, 2026-10-23) were the measurement behind the hooks. +- The dev shell's `quest` is the reviewed `quest-pinned` build + ([moq-dev/quest#344](https://github.com/moq-dev/quest/pull/344)), while + `bun run --silent quest` runs the checkout. Choose how hooks reach a + pinned `quest` outside the dev shell, for example an installed release + that `SETUP.md` asks contributors for, and say what happens for a + contributor without one. diff --git a/quest/m0/worktree-routes.md b/quest/m0/worktree-routes.md new file mode 100644 index 00000000..062bed03 --- /dev/null +++ b/quest/m0/worktree-routes.md @@ -0,0 +1,27 @@ +# [S] Live-check Claude's other worktree routes + +## Goal + +Every way Claude Code creates a worktree works with `quest worktree +hook`, or the README's "Claude Code checkouts" section says what doesn't: +`--worktree '#123'` and PR URLs, background sessions in agent view, +`claude remote-control` worktree mode, and workflow agents. Each route's +checkout is created, released when its agent stops, and removed. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [S], m0, from +[moq-dev/quest#350](https://github.com/moq-dev/quest/pull/350)'s suggested +follow-ups. + +- #350 verified subagents, `EnterWorktree`/`ExitWorktree`, a suspended + decision, a restored session, and a crash with Claude Code 2.1.316. +- PR routes: does Claude still fetch the PR's head when a hook creates the + worktree, since `WorktreeCreate` starts from `origin/HEAD`? +- Workflow agents: `SubagentStop` releases only a checkout named + `agent-`. If a workflow agent's worktree is named otherwise, it + is never released. +- Run from a session that is not itself worktree-isolated, in a scratch + repository with `QUEST_WORKTREE_HOME` isolated, as #350 did. Fix what + fails, or plan a quest for it. diff --git a/quest/m1/README.md b/quest/m1/README.md index 12a0b6b1..eb8ea81c 100644 --- a/quest/m1/README.md +++ b/quest/m1/README.md @@ -25,3 +25,4 @@ earlier "Later work" milestone became m2. - [Kix for any repository](/quest/m1/kix/README.md) - onboarding, read-only CI checks, contributor sandboxing, and the maintainer guide - [Quest log theme](/quest/m1/theme/README.md) - an MMO-style identity, copy, board, landing page, and CLI output for the demo and launch - [Launch material](/quest/m1/launch.md) - README, quickstart, demo, comparison, and launch-post drafts +- [Workers in a 5-minute cache](/quest/m1/worker-cache.md) - re-plan #276's worker/coordinator split and gate tickets, after confirming the cache premise diff --git a/quest/m1/kix/README.md b/quest/m1/kix/README.md index 3e1830a9..da2fa182 100644 --- a/quest/m1/kix/README.md +++ b/quest/m1/kix/README.md @@ -20,3 +20,4 @@ maintainers, so they need none of this first. - [Read-only CI](/quest/m1/kix/ci-read-only.md) - enrolled repositories keep pull-request CI read-only, checked at enrollment, with every trust boundary written down - [Contributor sandboxing](/quest/m1/kix/sandbox/README.md) - contributors' PR heads build in a VM, on stock Ubuntu and verified on macOS - [Onboarding guide](/quest/m1/kix/guide.md) - a complete maintainer path, from runner setup through a reviewed PR +- [Missing review flag](/quest/m1/kix/review-flag.md) - the inbox shows a PR's missing review before the merge click diff --git a/quest/m1/kix/ci-read-only.md b/quest/m1/kix/ci-read-only.md index 83e7a9aa..3f64d233 100644 --- a/quest/m1/kix/ci-read-only.md +++ b/quest/m1/kix/ci-read-only.md @@ -45,6 +45,12 @@ moq-dev/quest#246's Codex Security P1): moq-dev/quest's `land` environment was limited to `main` on 2026-10-28, and moq-dev/moq tracks its fix in [read-only secrets](https://github.com/moq-dev/moq/blob/main/quest/m0/ci/read-only-secrets.md). +- Noted 2026-11-01 (user, /quest-plan, from + [moq-dev/quest#246](https://github.com/moq-dev/quest/pull/246)): + moq-dev/moq's `.github/workflows/check.yml` passes the + `MBX_R2_ACCESS_KEY_ID` and `MBX_R2_SECRET_ACCESS_KEY` secrets to its + `pull_request` checks. They must move to an environment limited to + protected branches before moq enrolls. ## Related diff --git a/quest/m1/kix/review-flag.md b/quest/m1/kix/review-flag.md new file mode 100644 index 00000000..c954aee7 --- /dev/null +++ b/quest/m1/kix/review-flag.md @@ -0,0 +1,24 @@ +# [S] The inbox flags a missing review before the merge click + +## Goal + +kix's inbox shows, on each PR item, when no review counts on its head yet, +with the reason the land gate would give. A maintainer sees it before +picking merge, instead of having the click refused. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [S], m1, from +[moq-dev/quest#351](https://github.com/moq-dev/quest/pull/351)'s suggested +follow-ups. + +- #351 refuses the inbox's **Merge this PR** with the gate's reason only + after the click. Flag it up front from what the inbox already observes, + such as the PR's `latestReviews` and the App's `quest review` check, and + keep the click's live check as the authority. +- Keep the extra GitHub reads within the Worker's subrequest budget. + +## Required + +- [Land review](/quest/m0/kix/land-review.md) - the gate whose reason the inbox shows diff --git a/quest/m1/kix/setup-pr.md b/quest/m1/kix/setup-pr.md index d8563ff3..8cc42555 100644 --- a/quest/m1/kix/setup-pr.md +++ b/quest/m1/kix/setup-pr.md @@ -26,7 +26,13 @@ needs a runner before a project can enroll: the Claude hook entries in `.claude/settings.json`. The Worker publishes them through the same path as job branches, on a branch outside `quest/`. - The enrollment form asks, optionally, what the project is working toward, - and writes the answer as `quest/README.md`'s Goal. + and writes the answer as `quest/README.md`'s Goal. Amended 2026-11-01 + (user, /quest-plan): since + [moq-dev/quest#349](https://github.com/moq-dev/quest/pull/349), enrolling + is one **Enable** button on a row of the `/projects` picker, with no form. + On a row with no Quest files, **Enable** opens a short form holding only + this optional question, and submitting it opens the setup PR. Rows that + already have Quest files enable at once, as now. - An init refusal names the conflicting path on the setup page, as the CLI does; kix never deletes or renames a repository's files. - The pull request body says what the PR leaves out, since those steps need diff --git a/quest/m1/worker-cache.md b/quest/m1/worker-cache.md new file mode 100644 index 00000000..213954f6 --- /dev/null +++ b/quest/m1/worker-cache.md @@ -0,0 +1,31 @@ +# [M] Re-plan workers that fit a 5-minute prompt cache + +## Goal + +A decision, through `/quest-plan`, on whether background workers should do +one burst each within a 5-minute prompt cache while the coordinator runs the +long waits, and on gate tickets. The result is either quests planned +against the current skills or a recorded decision to drop the idea. + +## Plan + +Decided 2026-11-01 (user, /quest-plan of the follow-ups from the +2026-11-01 `/quest-complete` sessions): ✅ plan it, [M], m1, as +[moq-dev/quest#276](https://github.com/moq-dev/quest/pull/276)'s decision 2 +recommended when it was closed as superseded on 2026-11-01. + +- First confirm the premise: that sub-agents really keep only a 5-minute + prompt cache while the foreground keeps a 1-hour one. If they don't, say + so and drop the split. +- #276 (head + [811deae](https://github.com/moq-dev/quest/commit/811deaef7e4550901f0de158217e970e24bc6977)) + had workers do one burst with every tool call under 4 minutes, push only + to drafts, and terminate, while the coordinator ran full checks, + `quest review` rounds, and gated commands. Its + [gate tickets](https://github.com/moq-dev/quest/blob/811deaef7e4550901f0de158217e970e24bc6977/quest/m0/gate-tickets.md) + quest had `quest gate` return within 4 minutes with a token or a ticket. + Re-plan both against main's current skills, which already stopped waiting + on GitHub. +- Include the handoff fix from #276's open review finding: a finished + worker's draft stays held by its starter, so the coordinator's + `quest ready` is refused. diff --git a/quest/m2/README.md b/quest/m2/README.md index 9d13f500..e90466d2 100644 --- a/quest/m2/README.md +++ b/quest/m2/README.md @@ -15,7 +15,6 @@ additional login providers. This milestone does not gate the public release. - [Donor isolation](/quest/m2/donor-isolation.md) - stronger boundaries for untrusted shared jobs - [ChatGPT hosted runs](/quest/m2/chatgpt-hosted.md) - conditional on provider approval and current terms - [ChatGPT approval](/quest/m2/chatgpt-waitlist.md) - resolve hosted-use approval before implementation -- [Current landing status](/quest/m2/status-landing.md) - `quest status` drops a stale `landing-stopped` line and ignores superseded cancelled checks - [Worker dev setup](/quest/m2/worker-dev.md) - per-server cookies, seeded raw output, static assets, one fake GitHub, each test run alone - [Gate ownership everywhere](/quest/m2/gate-ownership.md) - delegated sub-cgroups for nested gates and Windows Job Objects - [Fewer git processes on Windows](/quest/m2/windows-git.md) - batched git lookups in the CLI and reused fixture repositories in tests