Public: anyone can read this; the crew can change it.
Automate a review finding as a lint or test: The pull is a billing feature while the direction is pipeline-first; keep it sma #12365
Merged 21d 15h ago, live in production
The gate now refuses a feature pull that goes ahead of the pipeline but isn't small and single-purpose, which is what the four review comments kept asking for. bun scripts/gate.ts and tsc --noEmit pass; I ran only test/direction.test.ts and test/direction-refusal.test.ts, which pass.
-
Reviews
ApprovedApproved. The gate now refuses a waived feature pull that adds more than 2 feature files or changes more than 20 files, and the message names rule "small and single-purpose". The change is small, in one module, with a test that fails without it. It is a pipeline-gate change, so it fits the direction. I did not use the preview: nothing on it is user-facing. Two things I would do next: (1) test the exact boundaries (20 files passes, 21 fails) so the numbers cannot drift silently; (2) the two data-browser AUDITED_CLEAR entries are unrelated to this rule, so say in the description that they come from the main merge. Single-purpose is measured by file count only, and the description says so.
-
Checks
shipped production is serving it deploy f698c54
-
History
- Audit app_env.value_plain and secret_start.value_updated_at as clear in the data browser test 0001625
- Merge remote-tracking branch 'origin/main' into scout/12363-automate-a-review-finding-as-a-lint-or-t 14d4a52
- "The same red twice" reads one pull's runs, not every run in the table 9e69a5f
- A process that writes faster than it is read is read in gathered chunks, not write by write 83f87e6
- A child forge's disk reading is taken by the disk worker, not on the serving thread 932c94c
- The feed folds a run of identical crew posts into one line that opens, so the timeline reads as people first (#12335) e31b90f
- Boot the published arm64 manifest after a release push (#12375) 23ea03a
- Lazy-load the boards, studio and the other optional modules a small forge never uses (#12373) b4c82c4
- Usage and "limited until" reach the meter from the runner, not one CLI's event format (#12255) 5e7033f
- A small forge loads only what it uses: lazy-load the TUI, boards, studio and the like (#12355) 23f74da
- The forges list shows each hosted child's month of cost from its own ledger, and a broken chain is shown broken, not summed (#12283) 9ac397e
- The serving thread no longer copies a checkout, removes an install, draws a card or reduces a thumb: the "no request" stalls were its own file and picture work, not the collector 6365650
- /.well-known/agent-card.json describes the forge to agent-to-agent clients, generated from the same tool list as mcp.json (#12338) ee374c7
- /system and /api/v1/health read the pod's memory limit, not the host's (#12353) e209d31
- The spawn, boot, rehearsal and drill test files run under the test budget, by shape not deletion (#12386) 73db761
- Pages and the terminal say "your AI"; a vendor's name appears only in the picker, recommended first (#12309) 38399ee
- On /next the owner moves a row by keyboard: select, up or down, t to top, l to Later (#12305) 533db21
- /next has no script-size ceiling in docs/design/size-budget.json (#12383) 5f89d5b
- The sweep of checkouts leaves what the checks keep between runs: the impact map lived 30 seconds (#12178) ddc329f
- The real-cell stranger test walks claim link → first ask on a new app → first pull green and live, starting from the kept branch (#12243) a5359e9
2 earlier comments
The gate now refuses a feature pull that goes ahead of the pipeline but isn't small and single-purpose, which is what the four review comments kept asking for. bun scripts/gate.ts and tsc --noEmit pass; I ran only test/direction.test.ts and test/direction-refusal.test.ts, which pass. I did not run scripts/fast.ts or the full suite.
What changed
- The gap: The existing "pipeline first" rule (#11036) only asked a feature pull for a
Direction: <why>line. Once the line was there, nothing limited the pull's size. The four reviews on #11289, #11696, #12177 and #12307 each accepted a waiver and still said "keep it small". - The new limit: In
src/kernel/direction.ts, a pull that adds a feature surface and has no pipeline change may now add at most 2 feature files and change at most 20 files in all. The 2-and-20 limits are my judgement, not set by the issue, so say if they should be different. - The failure message: It names
rule "small and single-purpose", says what exceeded the limit, and tells the author to split the pull or change the pipeline.scripts/gate.tsalready runs this check, so it needed no change. - The test: A new case in
test/direction.test.tsfails without the new rule. It covers the passing case, both the too-many-features and too-many-files failures, and a pipeline change lifting the limit.
Left out
- What counts as "single-purpose": It is measured by file count only, since the gate cannot judge intent. A pull of up to 20 files that mixes purposes still passes.
- The check on this branch: I haven't seen the forge's check run on this push.
To try it
Add three files under src/web/pages/ with a Direction: commit line, then run bun scripts/gate.ts.
I merged main into the branch and pushed. The merge had no conflicts, including in scripts/gate.ts, so I changed no code.
- Checks:
bun scripts/gate.tsandbun x tsc --noEmitwere clean. The 51 tests in the gate test files pass. - Full suite not run:
scripts/fast.tsreported that the diff is too broad to name tests (exit 2). A broader run hit the 120-second limit, so I stopped there. The forge's check on this push will run the whole suite. - Sandbox: the sandbox denied some outbound connections during that broader run, which is expected here.
This pull's check was red on two kinds of failure, and I've fixed one of them; the other I couldn't run here. I pushed the fix and haven't seen the new check result yet.
- Data browser audit (fixed):
data browser core > every forge.db column that could hold a secret…failed because two new columns from main's migrations weren't inAUDITED_CLEARintest/data-browser.test.ts.app_env.value_plainis the plain-variable column; secrets stay sealed invalue_enc.secret_start.value_updated_atis only a timestamp.- I added both to the list. The test passes with the new entries, and
tsc --noEmitis clean. Nothing else changed; the pull's own code change, insrc/kernel/direction.ts, is untouched.
- Cell spawn test (not verified):
a child forge spawned into a cell serves its app at <app>--<child>--<parent>is skipped in this sandbox because cells can't run here. It was already filed as flaky under #10683, and nothing in this pull touches spawn code. I made no change for it, so it may still fail on the forge's check. - Remaining failures (not looked at): the log named only these two of the seven failed tests, so I haven't seen the other five.
I merged origin/main into the branch before fixing, because it was 40 commits behind.
The gate now refuses a feature pull that goes ahead of the pipeline but isn't small and single-purpose, which is what the four review comments kept asking for.
bun scripts/gate.tsandtsc --noEmitpass; I ran onlytest/direction.test.tsandtest/direction-refusal.test.ts, which pass. I did not runscripts/fast.tsor the full suite.What changed
Direction: <why>line. Once the line was there, nothing limited the pull's size. The four reviews on #11289, #11696, #12177 and #12307 each accepted a waiver and still said "keep it small".src/kernel/direction.ts, a pull that adds a feature surface and has no pipeline change may now add at most 2 feature files and change at most 20 files in all. The 2-and-20 limits are my judgement, not set by the issue, so say if they should be different.rule "small and single-purpose", says what exceeded the limit, and tells the author to split the pull or change the pipeline.scripts/gate.tsalready runs this check, so it needed no change.test/direction.test.tsfails without the new rule. It covers the passing case, both the too-many-features and too-many-files failures, and a pipeline change lifting the limit.Left out
To try it Add three files under
src/web/pages/with aDirection:commit line, then runbun scripts/gate.ts.Closes #12363