Repository navigation
ci(evals): let compare runs use the subscription token on trusted PRs - #18505
Conversation
A compare dispatch of pr-run-plugin-evals.yml takes a credential input, api-key (default) or subscription. On subscription, compare-prepare runs check-trusted-trigger on the pull request and stops unless its author is on the trusted-actor list, and both passes run on MAINTENANCE_CLAUDE_CODE_OAUTH_TOKEN; the API key is not passed to them. The measuring pass gains a run-eval-subscription job, rendered from run-eval by sync-credential-legs.mjs: no key-credit gate, no credit-stop marker, no fallback leg. Its limit, credit or auth stop ends the pass with an error. api-key runs as before. docs/review/evals.md states the rule and its bounds, citing the owner decision that amends Q14 and Q53. Closes #18480 Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01UJUn7LPUb4rRDJ2JhJRGZf
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. |
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01UJUn7LPUb4rRDJ2JhJRGZf
|
claude-security-review reviewed Security review: PR #18505 (head 150c0f7)No security issues found. This PR lets a dispatched compare run of Checks on the new subscription path
Spend (not a finding)A critical-findings: 0 |
|
claude-review reviewed Code review: PR #18505, subscription-token compare runsNo blocking or advisory findings. I read every hunk of all 13 changed files in What I checked
Loosened checks. The changed assertions all follow from the key-only eval credential rule and the compare jobs' secrets, which the closing issue's "Loosened checks" section names as loosenings with a reason:
So they pass. The Spend (not a hold). A compare dispatched with Security. Trust-boundary questions are left to the dedicated security lane: whether dispatched Verifier dropped 0 of 0 candidates. |
|
The pr-verify verifier failed head What it wrote (38 lines)This pull request leaves the merge queue, and ci-status holds it out while it carries |
Post-merge mutation testingKilled 6, survived 1, timeout 0, no coverage 0, invalid 0, not run 0.
Surviving mutants
The run's summary has the full report. |
Closes #18480
Summary
The org API key is off (
CLAUDE_API_KEYS_DISABLED=true), so no compare run ofpr-run-plugin-evals.ymlcan run and eval-held PRs such as #18356 cannot land. The owner decided ("Eval runs on a subscription token, case pruning, and how #18356 lands", 2026-11-23, architecturedocs/owner-decisions.md, amending Q14 and Q53) that a compare run may use the maintenance subscription token, bounded. This PR adds that path and changes nothing on the API-key path.Fix
pr-run-plugin-evals.yml: a dispatch-onlycredentialinput (api-keydefault,subscription). Onsubscription,compare-preparerunscheck-trusted-triggerwithpr-number: ${{ inputs.pr }}. That is the existing trusted-actor list and mechanism, and it refuses withuntrusted-authorunless the PR author is listed.Stop on an untrusted pull request authorthen fails the job before any arm patch is built.compare-before/compare-afterget only the selected secret (inputs.credential != 'subscription' && secrets.MAINTENANCE_CLAUDE_API_KEY || '', the token likewise) and passcredentialthrough.compare-preparegainsactions: read, whichcheck-trusted-triggerneeds to read the run's re-runner.maintenance-measure-skill-edit-pass.yml: acredentialinput and aMAINTENANCE_CLAUDE_CODE_OAUTH_TOKENsecret.check-key-creditandrun-evalskip onsubscription. A newrun-eval-subscriptionjob runs on the token alone.scripts/sync-credential-legs.mjsrenders that job fromrun-evalthrough the new declarationscripts/credential-legs/maintenance-measure-skill-edit-pass.mjs, and the--checktest incallers.test.mjsholds it in sync. The job has no credit gate, no credit-stop marker and no fallback leg.ANTHROPIC_API_KEYis never set in it, and--no-publishand--max-cost-usdare unchanged. Its judge passesFALLBACK_READY: "true"toeval-handoff.mjs, so the token's limit, credit or auth stop counts as a stop: the pass uploads nothing andStop at the token's stopfails with::error::... no fallback leg runs.FALLBACK_CLAUDE_CODE_OAUTH_TOKENstays unused.lane-funding.jsonand thecallers.test.mjsleg exemptions: the compare jobs and the pass now read the key and the token, and are exempt only from the fallback leg, with a reason ending in(docs/review/evals.md). The suite/labelrun-evalstays key-only.docs/review/evals.md: the key-only line now states the subscription exception, its bounds and the owner decision.The pass needs its own job rather than an expression-selected credential in
run-eval, becausecallers.test.mjsforbids any step that references both Claude secrets.Verification
node --test --test-concurrency=4over.github/scripts/plugin-eval/*.test.mjs,.github/actions/resolve-config/callers.test.mjs,scripts/sync-credential-legs.test.mjs,.github/actions/check-kill-switch/check-kill-switch.test.mjs,.github/scripts/maintenance-measure-skill-edit/*.test.mjs,.github/actions/check-trusted-trigger/check-trusted-trigger.test.mjsand.github/scripts/pr-merge/release-eval-hold.test.mjs: 1082 pass, 0 fail. Earlier runs of the other suites that read these files (check-upstream-status,api-budget-coverage,live-config,trusted-actors,pr-merge/*,label-unblocked,check-label-sender.test.sh) also passed.credential-legs.test.mjsnow covers both credentials. Each credential input runs exactly one leg, the credit gate runs only forapi-key, andCLAUDE_EVALS_DISABLEDstops both. The truth table drives every token state and every launcher outcome through the subscription leg's stop condition, includinglimit-stop.workflow.test.mjscovers the author refusal. It evaluates the author step's and the stop step'sif:for both credentials, and checks that the refusal precedesBuild the arm patches. It also runscheck-trusted-trigger'sevaluateTriggeron a dispatched compare: our login's PR and a listed bot's PR proceed, and an unlisted author's PR stops withuntrusted-author. Each arm gets only the selected secret.node scripts/sync-credential-legs.mjs --check: in sync.actionlintis clean on both workflows.zizmor --offlinereports no findings.scripts/check-artifact-retention.shmatches 166 upload steps.Related
Owner decision authorizing the loosened checks, by line with the owner's words: ci(evals): let a compare run use the maintenance subscription token on our own PRs #18480 cites docs/owner-decisions.md#L364.
Refs: feat(evals): add /evals:audit, a read-only eval-suite health report #18356 and refactor(architecture): move the adr record and audit flows into action files #18188, the eval-held PRs this unblocks.
Refs: ci(evals): run evals on the API key alone, never subscription tokens #18268, which deleted the subscription and fallback legs. The fallback leg stays deleted.
Decision: owner-decisions row "Eval runs on a subscription token, case pruning, and how feat(evals): add /evals:audit, a read-only eval-suite health report #18356 lands" (melodic-software/architecture#200).
🤖 Generated with Claude Code
https://claude.ai/code/session_01UJUn7LPUb4rRDJ2JhJRGZf