Skip to content

paid screens: narrow screens derive setup instead of running the full gate (GST-1575) - #4056

Merged
capy-ai[bot] merged 4 commits into
mainfrom
capy/paid-screens-narrow-screens
Nov 6, 2026
Merged

capy-ai[bot] merged 4 commits into
mainfrom
capy/paid-screens-narrow-screens

Conversation

@garrytan

@garrytan garrytan commented Nov 6, 2026 •

Copy link
Copy Markdown
Owner
{
  "schema_version": 1,
  "pr": 4056,
  "head": "2ce98bf14c38052839c9dd0c48829075063258c1",
  "version": "1.96.0.0",
  "base": "main",
  "gate": {
    "focused": {
      "pass": 23,
      "fail": 0,
      "skip": 0
    }
  },
  "session_kind": "unattended",
  "head_tree": "3de8e3bad047066c9ebdb02454f5d40539614418",
  "product_patch_id": "e9aa32166a5fe99df8953097b8846ba72e0d1747",
  "gstack_version": "1.96.0.0",
  "review_depth": {
    "depth": "light",
    "class": "code",
    "runtime_lines": 18,
    "rules": "70895942bb8a8ee2",
    "base": "8d712d63ddb883379c371f9c0752854eba97eeb0",
    "registry": "8d712d63ddb883379c371f9c0752854eba97eeb0",
    "gate_scan": {
      "tagged": 0,
      "head": "2ce98bf14c38052839c9dd0c48829075063258c1"
    },
    "reasons": [
      "runtime=18"
    ],
    "risk": [],
    "mode": "panel"
  },
  "pregate": "requires-remote cleared @3de8e3bad047 (7 checks, current for 2ce98bf14c38)",
  "requires_remote": [
    "free-tests.yml/macos-named-regressions: https://github.com/garrytan/gstack/actions/runs/42172004406/attempts/1",
    "pregate.json/remote_gate: remote-gate tree=3de8e3bad047 tests=35849 skipped=69 runs=42172004406/1 profiles=ci-reuse/free-tests heads=2ce98bf14c38 verified=2026-11-06T06:09:26.838Z"
  ],
  "issues": {
    "fixes": [],
    "refs": [],
    "flakes": []
  },
  "docs": {
    "status": "current",
    "scope": "docs/, README.md, AGENTS.md, CLAUDE.md and the changelog.d fragment against main (read-only)"
  },
  "review_loop": {
    "passes": 2,
    "blocking_found": 0,
    "deferred": 0,
    "noted": 0,
    "fixed": 0,
    "scope": "frozen",
    "rounds": 2,
    "ledgers_read": 5,
    "dispatches": {
      "specialist": 6,
      "red-team": 2
    }
  }
}

What changed

The three failing-first selector tests: red on main, green on this branch (a narrow screen of a setup edit selects only the cases that test it)

The three failing-first selector tests: red on main, green on this branch (a narrow screen of a setup edit selects only the cases that test it).

Before/after as text
--- Before · main 8d712d6
+++ After · this branch
-(fail) a narrow screen of #4045 derives setup and selects its five cases
-(fail) a narrow screen of #4047 derives setup and selects its five cases
-(fail) a narrow screen of setup alone runs only the gate cases that invoke it
- 19 pass
- 3 fail
+(pass) a narrow screen of #4045 derives setup and selects its five cases
+(pass) a narrow screen of #4047 derives setup and selects its five cases
+(pass) a narrow screen of setup alone runs only the gate cases that invoke it
+ 23 pass
+ 0 fail

Why

PRs #4045 and #4047 each touched setup and paid for a narrow screen of all 113 gate cases, about $37 each. setup sat on the list of inputs every paid case is assumed to consume, but no paid CI run executes it. A narrow screen now treats setup like any other file and picks only the cases that test it, so those two diffs would have screened 5 cases.

Blast radius

The change touches only paid-case selection. Under --screen-policy narrow, setup leaves the full-gate list (NARROW_DERIVED_FULL_GATE_FILES in scripts/test-pr-profile.ts), and scripts/pr-dependencies.ts now counts modules/ references, so modules/loadouts.json is placed through scripts/modules.ts instead of being an unknown file. That is safe because pull_request runs, broad screens, --profile full and the train gate's full census (evals_all=true, scripts/train-gate.ts:114) still run every case before a merge. Evidence: the focused tests ran (23 pass), and the adversarial reviewer compared the old and new REPO_PATH derivation on the tree: the only file whose gate reach changed is modules/loadouts.json (0 to 113 cases).

Approvals

No approvals recorded for branch capy/paid-screens-narrow-screens.

Summary

Narrow paid screens stopped treating a setup edit as a reason to run every gate case. Before, any PR that touched setup paid for the full gate on its pre-train screen. Now the screen runs the cases that test setup, and broad screens, pull_request runs and the train census keep full coverage. modules/loadouts.json also stops counting as an unknown file. The harness pin for scripts/test-pr-profile.ts records the change as non-behavioral, because it changes which cases a narrow screen picks and never how a case runs.

Test Coverage

All new code paths have test coverage (Step 7 audit: 6 of 6 paths, all ★★★, in test/pr-shared-input-selection.test.ts).
Tests: 1726 → 1726 (+0 new files; one existing file extended)
Coverage: 100% value-weighted (100% including 0 weakly covered paths)
Test value: 0 tests written, 0 rejected by the authoring gate, 1 existing test extended, 0 paths weakly covered.
Regression proof: the three new tests fail on main 8d712d6 and pass on this branch (image above).
Tests ran: focused 23
Tests ran: harness-version 12 (bun test test/harness-version.test.ts, 12 pass after the pin repair; 4 failed before it, matching CI run 42169812331)
Earlier lane checks on this diff: bun run typecheck clean; 56 selector-dependent test files plus the module-size ratchet and parity suite gave 1478 pass and 4 fail, all 4 in test/ship-skip-actor.test.ts (5 s timeouts), which fail the same way on main 8d712d6 with the diff stashed.

Pre-Landing Review

Pre-Landing Review: 1 issue — 0 auto-fixed, 1 skipped (informational, below the crew's blocking floor), 0 deferred, 4 noted
REVIEW_LOOP: passes=2 blocking_found=0 deferred=0 noted=0 fixed=0 scope=frozen ledgers_read=5 dispatches=8
Gate edits: none detected (GATE_SCAN tagged=0 at fab51d4 and 916d5df)
Outside review: openai/gpt-6.1-sol (host subagent), completed, no findings: "approve because the setup exemption remains narrow-screen-only, while broad selection and unknown-input fallbacks retain full-gate coverage."

Pass 1 (full panel on fab51d4: batched specialist with testing, security, state-machines and red-team checklists, plus the Step 7 coverage audit) found one informational test gap. Between pass 1 and Step 11, CI found test/harness-version.test.ts red (the pinned scripts/test-pr-profile.ts changed with no HARNESS_VERSION decision); 916d5df records it as non-behavioral. Pass 2 (batched specialist and Red Team on the fab51d4..916d5df range) found nothing. Step 11 (native adversarial and outside voice on the whole diff at 916d5df) found four items below the floor, listed below.

Review notes

Below the blocking floor (advisory, informational, test-gap or wording items); recorded here and not fixed in this PR.

  • INFORMATIONAL test/pr-shared-input-selection.test.ts:143 The "every other shared input" test loops over a six-entry fixture, not every PR_FULL_GATE_FILES entry minus setup, so widening the narrow exemption to another real full-gate input would stay green. Proposed test: iterate the concrete PR_FULL_GATE_FILES entries and assert NARROW_DERIVED_FULL_GATE_FILES equals ['setup'].
  • INFORMATIONAL scripts/test-pr-profile.ts:331 The doc comment on NARROW_DERIVED_FULL_GATE_FILES says scripts/pr-dependencies.ts maps setup to the cases that invoke it. It does not: setup reaches its 2 cases through touchfiles. Under EVALS_HOST=codex every case runs ./setup --host codex, so a local narrow screen of a setup edit under-selects there. CI's evals.yml sets no EVALS_HOST, and the train census runs every case. The changelog fragment was corrected in 2ce98bf.
  • INFORMATIONAL changelog.d/capy-paid-screens-narrow-screens.md:1 A narrow screen of a loadouts-only edit now runs zero paid cases, because its reader reaches every gate case. Fixed in 2ce98bf: the fragment now says so.
  • INFORMATIONAL docs/TESTING_INTERNALS.md:1203 The doc says modules/ references count, while DERIVABLE_PREFIXES omits modules/. An unreached modules/ file still restores the full gate, which fails safe.
  • INFORMATIONAL scripts/test-pr-profile.ts:563 shadowSelection and checkoutExercised still skip PR_FULL_GATE_FILES, so narrow-screen shadow numbers for a setup edit leave out its exercised consumers. This affects only the shadow numbers.

Exploratory QA

Report-only smoke on the selector (no browser surface): bun test test/pr-shared-input-selection.test.ts (23 pass), covering a narrow screen of setup alone, the #4045 and #4047 diffs, broad and --profile full fallbacks and a loadouts-only edit. The adversarial reviewer also probed a setup-only edit directly: a narrow screen selects 2 gate cases (gstack-upgrade-happy-path, skillmd-setup-discovery), and a broad screen still falls back to the full gate. bun test test/harness-version.test.ts 12 pass. No checks failed, were blocked or were left unrun.

Design Review

No frontend files changed — design review skipped.

Eval Results

No prompt-related files changed — evals skipped.

Review bot comments

No review bot comments.

Plan Completion

Plan completion audit: not run (no plan is bound to this branch and no docs/designs/ file matches). This is a bug fix with failing-first tests (R65: no autoplan for fixes).

Verification Results

No Step 8.1 obligations (no plan bound). The failing-first tests are the verification: 3 FAIL on main, 3 PASS on this branch.

TODOS

No TODO items completed in this PR.

Documentation

Scope: the branch diff against main, plus the working tree, which had no uncommitted changes. The docs changed in the diff (docs/TESTING_INTERNALS.md, docs/ship-policy.md, and the changelog.d fragment) were read against the code in scripts/test-pr-profile.ts and scripts/pr-dependencies.ts. Result: current. The docs name NARROW_DERIVED_FULL_GATE_FILES, the exemption that lets a narrow screen derive setup like any other file, and say pull_request runs, broad screens and --profile full keep the full gate. They also say modules/ data references now count, so modules/loadouts.json is placed through scripts/modules.ts. The remaining PR_FULL_GATE_FILES mentions (the 'full-gate input' triage entry and the closure note) are still accurate. Debt: none found.

Test plan

  • bun test test/pr-shared-input-selection.test.ts: 23 pass, 0 fail
  • bun test test/harness-version.test.ts: 12 pass, 0 fail
  • bun run typecheck: clean (lane run, unchanged product code since)
  • Free Tests CI at the pushed head (the full free suite; see checks)

…ves through its reader (GST-1575)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
@trunk-io

trunk-io Bot commented Nov 6, 2026 •

Copy link
Copy Markdown

😎 This pull request was merged.

garrytan and others added 3 commits November 6, 2026 05:40
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…tion only) (GST-1575)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…edits wait for the train census (GST-1575)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
@capy-ai
capy-ai Bot merged commit 12d18a2 into main Nov 6, 2026
43 checks passed
@github-actions

github-actions Bot commented Nov 6, 2026

Copy link
Copy Markdown
Contributor

E2E Evals: ✅ PASS

[test:paid] VERDICT GREEN — lane gate/pr, attempt 1
  rule 57/57 · behavior 0/0 · judge 0/0 · quarantined 0 (0 failing the lane)
  SKIPPED 0 · INFRA 0 · INCOMPLETE 0 · unattributed 0 · ACTION REQUIRED 0
  wall 5m24s · cost $18.85 known + 2 of 57 trial(s) cost unknown

52 executed, 0 reused rule/judge records | 0 manual accepted (unscored; no score-cache credit) | $18.02 rule/judge cost | reconcile exit: 0

Profile: pr / mode pr; selected behaviors: 57, judges: 0. Deferred to scheduled/release coverage: 209 behaviors and 0 changed prompt files. Deferred checks did not run and receive no PR-pass credit.

Rule and judge shards
Shard Automated result Manual/unscored Executed Reused Status Cost
e2e-ship-docsync/skill-e2e-ship-docsync--ship-docsync-current 1/1 0 1 0 ✅ $1.06
e2e-ship-docsync/skill-e2e-ship-docsync--ship-docsync-store 1/1 0 1 0 ✅ $0.99
e2e-deploy/skill-e2e-deploy--setup-deploy-workflow 1/1 0 1 0 ✅ $0.14
e2e-qa-functional-fix/skill-e2e-qa-functional-fix 2/2 0 2 0 ✅ $0.98
e2e/skill-e2e-test-value 3/3 0 3 0 ✅ $0.72
e2e/skill-e2e-plan--plan-review-report 1/1 0 1 0 ✅ $1.1
e2e-qa-callers/skill-e2e-qa-callers--ship-exploratory-unavailable 1/1 0 1 0 ✅ $1
e2e-ship-docsync/skill-e2e-ship-docsync--ship-docsync-timeout-unsettled 1/1 0 1 0 ✅ $0.21
e2e-ship-docsync/skill-e2e-ship-docsync--ship-docsync-late-result 1/1 0 1 0 ✅ $0.35
e2e/skill-e2e-coverage-audit 2/2 0 2 0 ✅ $0.4
e2e-plan-tune/skill-e2e-plan-tune 1/1 0 1 0 ✅ $0.12
e2e-browse/skill-e2e-bws 3/3 0 3 0 ✅ $0.16
e2e-ship-docsync/skill-e2e-ship-docsync--ship-docsync-missing-asset 1/1 0 1 0 ✅ $0.26
e2e-docsync-spawned/skill-e2e-docsync-spawned 1/1 0 1 0 ✅ $0.52
e2e-third-party-actions/skill-e2e-third-party-actions 2/2 0 2 0 ✅ $0.17
e2e-ship-docsync/skill-e2e-ship-docsync--ship-docsync-missing-marker 1/1 0 1 0 ✅ $0.17
e2e-qa-callers/skill-e2e-qa-callers--review-exploratory-small-cli 1/1 0 1 0 ✅ $0.85
e2e-qa-callers/skill-e2e-qa-callers--ship-exploratory-plan-checks 1/1 0 1 0 ✅ $1.03
e2e-skillify/skill-e2e-skillify 1/1 0 1 0 ✅ $0.07
e2e-qa-callers/skill-e2e-qa-callers--ship-exploratory-late-input 1/1 0 1 0 ✅ $1.21
e2e-qa-functional/skill-e2e-qa-functional 2/2 0 2 0 ✅ $0.79
e2e-ship-docsync/skill-e2e-ship-docsync--ship-docsync-recovery 1/1 0 1 0 ✅ $0.41
e2e-ship-docsync/skill-e2e-ship-docsync--ship-docsync-stale-after 1/1 0 1 0 ✅ $0.41
e2e-review/skill-e2e-review 1/1 0 1 0 ✅ $0.21
e2e-hermetic/skill-e2e-hermetic-canary 2/2 0 2 0 ✅ $0.06
e2e-ship-docsync/skill-e2e-ship-docsync--ship-docsync-completion 1/1 0 1 0 ✅ $1.22
e2e-session-intelligence/skill-e2e-session-intelligence 1/1 0 1 0 ✅ $0.06
e2e-qa-workflow/skill-e2e-qa-workflow--qa-bootstrap 1/1 0 1 0 ✅ $0.09
e2e/skill-e2e-investigate-owned-termination 2/2 0 2 0 ✅ $0.17
e2e/skill-e2e-ship-hook-refresh 1/1 0 1 0 ✅ $0.09
e2e-ship-docsync/skill-e2e-ship-docsync--ship-docsync-launch-failure 1/1 0 1 0 ✅ $0.17
e2e/skill-e2e-investigate-owned-completion 1/1 0 1 0 ✅ $0.07
e2e-learnings/skill-e2e-learnings 1/1 0 1 0 ✅ $0.07
e2e-design/skill-e2e-design--plan-design-review-no-ui-scope 1/1 0 1 0 ✅ $0.08
e2e/skill-e2e-ship-hook-consent 2/2 0 2 0 ✅ $0.25
e2e/skill-e2e-workflow 3/3 0 3 0 ✅ $0.36
e2e-ship-docsync/skill-e2e-ship-docsync--ship-docsync-stale-before 1/1 0 1 0 ✅ $0.44
e2e-ship-docsync/skill-e2e-ship-docsync--ship-docsync-failure 1/1 0 1 0 ✅ $0.69
e2e-qa-callers/skill-e2e-qa-callers--ship-exploratory-small-cli 1/1 0 1 0 ✅ $0.87
Fail-closed reconciliation
est.ts
  slice 6  passed             78s  test/skill-e2e-ship-docsync.test.ts#ship-docsync-recovery
  slice 6  passed             37s  test/skill-e2e-plan-ceo-plan-mode.test.ts
  slice 6  passed             33s  test/skill-e2e-office-hours-auto-mode.test.ts
  slice 7  passed             60s  test/skill-e2e-ship-docsync.test.ts#ship-docsync-late-result
  slice 7  passed             55s  test/skill-e2e-docsync-spawned.test.ts
  slice 7  passed             47s  test/skill-e2e-ship-docsync.test.ts#ship-docsync-missing-asset
  slice 7  passed             32s  test/skill-e2e-bws.test.ts
  slice 7  passed             16s  test/skill-e2e-third-party-actions.test.ts
  slice 7  passed             21s  test/skill-e2e-plan-tune.test.ts
  slice 7  passed             38s  test/skill-e2e-coverage-audit.test.ts
  slice 7  passed             37s  test/skill-e2e-ship-docsync.test.ts#ship-docsync-timeout-unsettled
  slice 7  passed             25s  test/skill-e2e-ship-docsync.test.ts#ship-docsync-missing-marker
  slice 7  passed             33s  test/skill-e2e-ask-user-question-format-compliance.test.ts
  slice 8  passed             25s  test/skill-e2e-ship-docsync.test.ts#ship-docsync-launch-failure
  slice 8  passed              8s  test/skill-e2e-session-intelligence.test.ts
  slice 8  passed             36s  test/skill-e2e-ship-hook-consent.test.ts
  slice 8  passed             23s  test/skill-e2e-investigate-owned-termination.test.ts
  slice 8  passed             27s  test/skill-e2e-ship-hook-refresh.test.ts
  slice 8  passed             14s  test/skill-e2e-design.test.ts#plan-design-review-no-ui-scope
  slice 8  passed             24s  test/skill-e2e-investigate-owned-completion.test.ts
  slice 8  passed             22s  test/skill-e2e-qa-workflow.test.ts#qa-bootstrap
  slice 8  passed             12s  test/skill-e2e-learnings.test.ts
  slice 8  passed             12s  test/skill-e2e-diagram.test.ts
[test:paid] collector final outcomes: 52 executed, 0 reused; 52 passed, 0 failed, 0 manual accepted (unscored; no score-cache credit) (52 attempt records from 39 collectors; every record counts)
[test:paid] deselected testcases, zero credit (193):
[test:paid]    175  sibling case of a case shard (its own shard runs it)
[test:paid]     13  outside the run's case selection
[test:paid]      5  periodic-tier case (this lane runs gate)
[test:paid] VERDICT GREEN — lane gate/pr, attempt 1
  rule 57/57 · behavior 0/0 · judge 0/0 · quarantined 0 (0 failing the lane)
  SKIPPED 0 · INFRA 0 · INCOMPLETE 0 · unattributed 0 · ACTION REQUIRED 0
  wall 5m24s · cost $18.85 known + 2 of 57 trial(s) cost unknown
[test:paid] exercised-path map (shadow, non-blocking): 7 MAP_GAP line(s) over 53 executed case(s) with recorded commands
  MAP_GAP plan-review-report bin/gstack-plan-reality: non-blocking for this PR; the next census refresh widens the map (docs/TESTING_INTERNALS.md#exercised-path-map)
  MAP_GAP plan-review-report browse/dist/browse: non-blocking for this PR; the next census refresh widens the map (docs/TESTING_INTERNALS.md#exercised-path-map)
  MAP_GAP plan-review-report design/dist/design: non-blocking for this PR; the next census refresh widens the map (docs/TESTING_INTERNALS.md#exercised-path-map)
  MAP_GAP ship-exploratory-late-input bin/gstack-review-plan: non-blocking for this PR; the next census refresh widens the map (docs/TESTING_INTERNALS.md#exercised-path-map)
  MAP_GAP ship-exploratory-plan-checks bin/gstack-review-plan: non-blocking for this PR; the next census refresh widens the map (docs/TESTING_INTERNALS.md#exercised-path-map)
  MAP_GAP ship-exploratory-small-cli bin/gstack-review-plan: non-blocking for this PR; the next census refresh widens the map (docs/TESTING_INTERNALS.md#exercised-path-map)
  MAP_GAP ship-exploratory-unavailable bin/gstack-review-plan: non-blocking for this PR; the next census refresh widens the map (docs/TESTING_INTERNALS.md#exercised-path-map)
[test:paid] report: every planned shard accounted and passed

Sliced lane: planner → duration-packed executors → fail-closed report. Behavior cases run a pre-registered 3-trial panel (PASS at 2/3 with no contract violation); a PASS 2/3 is shown with its failed trial, never as a clean pass. Reused results retain their original provenance and expiry.

Dispatched narrow screen (gstack-ship-queue ready --screen) of merge commit 97d12c8605bec9e604fa79aeb15566863f33b6fa.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant