Repository navigation
feat(app-control): record a control skill's launch model and make ready mean usable from empty data - #16370
Conversation
… from empty data The control-skill contract gains "The launch model": `## Launch` starts the app from empty data with migrations and seed, in a per-run data directory where the app keeps data, and records `Data:`, `Side by side:` and, for a short-lived app, `Session:` lines. The Ready rule now covers port ownership and credential validity. Discovery's Run, Ready and Data rows ask for these, create's proof launches from empty state, drive's Ready rule names them, and refresh treats missing lines as doc drift. `/app-control:map check` gains the `launch-model` rule. The check eval fixtures carry the new lines, and check-missing-launch-model is a new case for the rule. Refs: #15798 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_015te8Csz4bqxpok4iu8Mcrd
…ol skills control-claude-code and control-claude-code-plugins now state their launch model under `## Launch`: no per-run data directory, because a run reuses the signed-in Claude Code config directory; sessions run side by side under distinct `<session>` names, since `launch` reserves each name with a lock file; and one new session holder per drive. control-claude-code's Ready states that port ownership and credential validity are not exposed: the session line only pings the socket and does not change Ready's exit, and Ready stops before any request. Refs: #15798 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_015te8Csz4bqxpok4iu8Mcrd
The create-verification-skill row's usable-state readiness candidate, left "not taken; owner to decide", is now taken in app-control per the owner's 2026-11-12 decision. The app-control:map row records the launch model and Ready rules with their citations, and its shifted line citations are updated. Refs: #15798 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_015te8Csz4bqxpok4iu8Mcrd
Refs: #15798 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_015te8Csz4bqxpok4iu8Mcrd
Ready's port-owner check named only the instance a run launched, which left no fit already-running app for drive's bare action and --attach. The port now belongs to the instance the run drives: the one it launched, or the pid the person attached. The legacy check eval's prompt states its hub carries the launch model lines, the new case's scaffold drops a comment, and the upstream record's Ready range moves to the section's current lines. Refs: #15798 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_015te8Csz4bqxpok4iu8Mcrd
…odel Resolve two conflicts by keeping main's newer text and re-applying the launch-model changes on top: - map/reference/refresh.md: main's Doc drift row names a state the Preconditions line does not name; the branch's missing Data: or Side by side: line is added to it. - docs/upstream/cursor-pstack.md: the branch's rewritten rows keep main's #15797 addition to the app-control row, and the branch's own line citations into map SKILL.md and prove.md move to where the merged text sits. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ts hub cites The fixture hub's Data line says the run-shop skill migrates and seeds a new SQLite file, but the fixture's run-shop skill had neither step. A run on opus reported that mismatch in all three runs, which the case's judge grader counts as inventing a Data-line problem. Co-Authored-By: Claude Fable 5.2 <[email protected]>
Three drive ready cases against a hub whose Ready only checks that the port answers, with a driver CLI stub that reports the listening pid and the API's answer to the run's credential: - ready-port-held-by-other-process: the port answers from a pid other than the launch record's; expects not ready naming the port owner, no launch and no process stopped. - ready-credential-rejected: the launched pid holds the port and whoami returns 401; expects a whoami call and not ready naming the credential. - ready-owned-port-valid-credential: control; expects ready. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Handing this pull request back to GitHub Work (desk): the laptop session's commits are done, it will not push to this branch again, and it has stopped its own eval runs here. Take it to ready and merge under the owner's decision recorded on issue 15798. What the laptop session added, head
For the body: the measured head stays Two follow-up points from building the Ready cases: |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Lane run report
Failed GitHub API calls
|
|
claude-security-review reviewed Security review: incremental, 3bc7599..018f748I found no security issues. This lane reviewed an earlier head of this pull request, so this pass was blocking only: it reports CRITICAL and IMPORTANT findings and drops SUGGESTION ones. Scope: the list had 4 files to read, and I read every hunk of each:
The other two What changed:
What I checked:
critical-findings: 0 |
|
claude-review reviewed Code review: incremental,
|
The #15797 part of the create-verification-skill row cited lines this branch's own edits moved: the contract's Drive steps rule, check-map.sh's drive-result check and its tests, drive's stated-result rule, and map's refresh triage. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The check-missing-launch-model recipe migrated into a mktemp path that its seed and server steps never used, so the hub's Data line described a per-run database the recipe did not build. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…recipe check-missing-not-driven-reason, check-over-size-budget and check-dead-index-line ship a run-shop recipe with no migrate or seed step and a fixed port 8080, but their hubs said a per-run SQLite file from migrate and seed and a port per run. They now carry the lines check-copied-recipe uses for the same recipe. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ntract The shared hub's Ready was `cli/shop health`, which exited 0 whichever process held the port and made no credential call, while the contract puts both checks in the Ready command and has drive read its exit status. The hub's Ready is now `cli/shop ready <run dir>`, which checks the listener against the launch record and calls GET /api/me, exiting 4 or 3 on failure. The graders look for that command instead of `health` and `whoami`. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
One thing before this merges: the three |
Drive's bare action reused any running app it judged fit, but the Ready rule's port owner accepts only the instance this run launched or an attached pid, so a found instance could never pass. Per the owner's decision, drive now reuses only the instance in this run's launch record under --out; any other running app is reached only through --attach. The Gotcha says the same. Unattended behaviour is unchanged. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…e changelog fragment Co-Authored-By: Claude Fable 5.2 <[email protected]>
|
Result of running the three
The base run ( |
…ly-exit grep The Data check piped one grep into `grep -q`, which the pipefail-grep-q hygiene gate refuses: under pipefail a producer killed by SIGPIPE makes a present match read as absent. The lines are captured first, then tested. Co-Authored-By: Claude Fable 5.2 <[email protected]>
|
Base result for the three Setting aside the broken
So base and head behave almost the same on these cases: the fixtures and the prompt (the stub prints both pids; the config names the credential; the prompt asks for Recommendation: merge under the owner's recorded decision without counting these three cases as evidence, and either drop them from this pull request or fix them in the follow-up that fixes |
|
The pr-verify verifier failed head What it wrote (33 lines)This pull request leaves the merge queue, and ci-status holds it out while it carries |
The launches-nothing grader matched any Bash call that mentioned the server's command line, so quoting the launch record failed a correct run. The pattern now needs the command at the start of the call or after a shell separator, and the samples add a quoted mention that must pass and a launch after another command that must fail. Co-Authored-By: Claude Fable 5.2 <[email protected]>
…ready-* cases The anchored launches-nothing pattern missed a launch behind an environment assignment, setsid, exec, timeout, sudo, bash -c, backticks or a brace group. It now allows a run of prefix words and those openers, with a must-fail sample for three of the forms. Co-Authored-By: Claude Fable 5.2 <[email protected]>
Post-merge mutation testingKilled 4, survived 2, timeout 0, no coverage 0, invalid 0, not run 0.
Surviving mutants
The run's summary has the full report. |
Refs: #15798
Summary
Problem: a control skill did not record how its app is launched and isolated, and "ready" could mean only that a process answers. Intent: align the launch and health check with the upstream verification skill the issue cites, so ready means a user could use the app, starting from nothing.
The control-skill contract now requires a start from empty data and a recorded launch model, the Ready rule covers port ownership and credential validity, and the create flow's prove step launches from empty state. The two-version eval compare the issue asks for has run: met on opus, not met on sonnet on one case drop. The owner decided on 2026-11-15 to merge with that drop stated here ("go w/ recommednations"); the record is under Eval record below.
Fix
plugins/app-control/reference/control-skill.md): a new "launch model" rule. A run starts from empty data with migrations and seed, in a new data directory per run where the app keeps data. The hub's## Launchsection recordsData:,Side by side:and, for a short-lived app,Session:(build once, one isolated session per drive)./app-control:drive): the port must belong to the instance the run drives, an attached instance included, and credentials must be valid, not only that something answers./app-control:map: discovery asks for the launch, ready and data facts; the prove step launches from empty state;checkgains alaunch-modelrule that requires theData:andSide by side:lines; refresh treats a missing line as doc drift, which is how existing control skills pick the lines up.control-claude-code(harness-ops) andcontrol-claude-code-plugins.Every value is the consumer's: the data directory, the isolation model and the checks are recorded in the consumer's control skill, never assumed by the plugin.
Limits to name, both recorded as gap lines the contract allows: this repository's own app is a Claude Code terminal session, which reuses the person's signed-in config directory, so its hubs record
Data: nonewith the reason; and its driver's Ready does not yet prove who holds the session socket or that the login is valid (Port owner: not exposed,Credentials: not exposed). The issue's demo of Ready failing on a held port therefore does not hold for this repository's own control skill.Verification
check-map.test.sh: 87 cases, 0 failed (the 6 new cases failed first);check-map-parts.test.sh: 5 cases, 0 failed. Both run again by the session that opened this PR.check-missing-launch-modeland the existing cases' updated fixtures pass the static validator with no failure.launch-modelfinding from the check.Left out: no app was launched (the dogfood values come from reading the driver); a compare at the merged head (see Eval record); any run of the three
ready-*eval cases added after the compare.Eval record
Registered before any run; launched by the owner in the local eval-runner session; 204 of 204 batches valid; no usage-limit stop; no rerun; Claude Code 2.1.325; 135.30 USD list price against a 220 USD cap. 50 existing cases plus the new case
check-missing-launch-model, 3 runs per side, margin 0.05; the eval case files were identical on both sides.check-copied-recipefell from 0.83 to 0.50 (run scores before 0.5, 1, 1; after 0.5, 0.5, 0.5). Every failing reply says the hub's Launch steps are copied from nowhere; therun-shopskill they copy sits beside the control skill. This PR does not change the check's copied-recipe step, which does not say where a recipe lives. A follow-up PR fixes that step with its own compare of this case.threads-capture-recheck-fails-interactiveandunattended-production-write-off(too few counted after-side runs).plugins/app-control:reference/control-skill.md,skills/drive/SKILL.md,skills/drive/reference/evidence.md,skills/map/SKILL.md,skills/map/reference/prove.mdandskills/map/reference/refresh.md;run-shop.mdfixture gained the migrate and seed steps its hub cites, and threeready-*eval cases were added. Skill text changed on the branch after the measured head only in844a016cfe, below.09e6b108ac(review fix): no file underplugins/app-control; re-points line citations indocs/upstream/cursor-pstack.md.e62d2fcf32(review fix):evals/check-missing-launch-model/fixtures/run-shop.md; no skill text.edfd690724(review fix):evals/check-missing-not-driven-reason/fixtures/control-shop.md,evals/check-over-size-budget/fixtures/control-shop.md,evals/check-dead-index-line/fixtures/control-shop.md, all three as measured in the compare; no skill text.b62956bb78(review fix): the threeevals/ready-*cases (case, hub, CLI and sample files); no skill text.844a016cfe(review fix):skills/drive/SKILL.md, the bare action row and the "An app already running is not yours" Gotcha. This changes skill text after the measured head, on the owner's decision of 2026-11-15: drive reuses only the instance in this run's launch record under--out, and any other running app is reached only through--attach. The compare was not run again for it.skills/map/scripts/check-map.sh: thelaunch-modelData check no longer pipes into an early-exit grep (same findings;check-map.test.sh87 cases, 0 failed); no skill text.evals/ready-*cases: thelaunches-nothinggrader counted any Bash call that mentioned the server's command line; it now needs the command at the start of the call or after a shell separator, with a must-pass sample that quotes the command line; no skill text.The compare was not run again at this head.
Related
docs/upstream/, rows for the launch and ready rules.plugins/app-control/evals/, plus the new case.Remaining
check-copied-recipe.ready-*eval cases have never been run.🤖 Generated with Claude Code