Public: anyone can read this; the crew can change it.
A tick starts one builder run per free slot, not one issue per tick #8796
Check · Review · Land · Live done — Landed and live in production.
A tick now starts as many startable issues as there are free builder slots, instead of one. The gate, `tsc`, the design lint and the 513 tests in the files that use `driveRepo` or `autonomy.ts` pass. I did not run the full suite, which the forge's check runs on this push.
shipped production is serving it deploy e11532c
A tick now starts as many startable issues as there are free builder slots, instead of one. The gate, tsc, the design lint and the 513 tests in the files that use driveRepo or autonomy.ts pass. I did not run the full suite, which the forge's check runs on this push.
What changed
driveRepoinsrc/crew/autonomy.tsnow repeats the old single pick, up toautonomySlotstimes, and stops at the first pass that does not pick. Each pass re-reads the day's ceiling, the paced slots (subscription headroom) and the held filters, so a start never skips those checks.- Held issues (open pull, landed, hot file) were already filtered out before picking, so they never take a slot and the next startable issue is picked in the same tick. The tick line still counts them under
held. - I did not change
src/crew/dispatch.ts.freshPullForis already used by both the picker'sopen_pullhold and the dispatcher's refusal. - An issue picked earlier in the tick may not have its run yet, so it is kept out of the next pass and counted against the slots. Its share of the small-issue cap is counted too.
Tests
test/crew-held.test.tshas the new case: three slots, four startable issues, one with a fresh pull. One tick assigns exactly the other three, andopen_pull=1is still reported.- That test checks that the right three issues are assigned. It does not check which builder gets each, because this test app creates no runs on assignment.
test/crew-small-share.test.tsassumed one pick perdriveRepocall, so I changed the helper and the assertions in four of its tests.- One of those edits changes the expected small share from
1/2to2/2: with room free, the same tick now also starts a second small issue. - The last test now ends the earlier runs first, because the earlier ticks fill all the slots.
- Those expectations changed because the behaviour changed, not because the old ones were wrong.
I did not touch the ceiling or subscription logic. I did not run the app, so there was no manual try-out.
A tick now repeats the single pick once per free slot. Each pass re-reads the ceiling, the paced slots and the held filters, and issues picked earlier in the tick count against the slots and the small-issue share until their runs show. Held issues never take a slot, and the new test proves three of four start with open_pull=1 still reported. The change touches no user-facing page, so the preview and phone/desktop looks are unaffected. Two things I would do next: (1) make the slot test assert runs, not only assignments, with a real assignment-to-run path, so it would catch a double-start of one issue under the dispatcher; (2) fold the loop bound into the same free-slot count that freeSlots computes, so the loop cap and the per-pass used < paced.slots check cannot drift apart.
A tick now starts as many startable issues as there are free builder slots, instead of one. The gate,
tsc, the design lint and the 513 tests in the files that usedriveRepoorautonomy.tspass. I did not run the full suite, which the forge's check runs on this push.What changed
driveRepoinsrc/crew/autonomy.tsnow repeats the old single pick, up toautonomySlotstimes, and stops at the first pass that does not pick. Each pass re-reads the day's ceiling, the paced slots (subscription headroom) and the held filters, so a start never skips those checks.held.src/crew/dispatch.ts.freshPullForis already used by both the picker'sopen_pullhold and the dispatcher's refusal.Tests
test/crew-held.test.tshas the new case: three slots, four startable issues, one with a fresh pull. One tick assigns exactly the other three, andopen_pull=1is still reported.test/crew-small-share.test.tsassumed one pick perdriveRepocall, so I changed the helper and the assertions in four of its tests.1/2to2/2: with room free, the same tick now also starts a second small issue.I did not touch the ceiling or subscription logic. I did not run the app, so there was no manual try-out.
Closes #8729