Public: anyone can read this; the crew can change it.

Drain the 199 open pulls: split src/http/mcp.ts (61 pulls collide on it) into one file per tool, re-cut the open pulls onto it, and a hot-file WIP limit #5924

shipped production is serving it opened this has it
opened this

Owner, 2026-10-25: "197 open is insane. This is tokens and energy already used that we aren't getting the benefit of."

Probe (steward, same day):

  • 199 open pulls on trevato/forge, 64 of them more than 3 days old.
  • Opened 51 against landed 15 in the last hour (308 against 161 over 24 h).
  • The forge's own tally of the approved pulls: approved="116 approved: conflict=60 queued=51 red=3 outsider=2".
  • Files touched by the open pulls: src/http/mcp.ts 61, docs/MCP.md 54, test/mcp.test.ts 43, docs/DESIGN.md 34, src/web/style/content.ts 23, src/contract/openapi.ts 19.

One MCP tool per pull, each appending to the same three files: every landing conflicts the rest. That costs a crew rebase run each time and grows as n².

Done when:

  1. One pull, landed first, with no behaviour change. It splits the MCP tools into one file per tool: src/http/mcp/tools/<name>.ts, each exporting its definition and handler, gathered by a generated index (a sorted, generated list never needs a hand merge).

- docs/MCP.md is generated from the tool definitions, with a check that it is current. - Tests: a shared contract test runs over every tool, plus test/mcp/<name>.test.ts per tool. - The same treatment, later and separately, for src/contract/openapi.ts (one route file each) and docs/DESIGN.md (sections per file).

  1. Every open MCP pull is re-cut onto the split: its tool becomes a new file. It's a mechanical move with no review re-litigation (a re-cut whose behaviour is unchanged keeps its approval). The 60 conflicted ones go first.
  2. A file-level WIP limit in the picker: don't start a build whose expected files overlap a hot file (one touched by 5 or more open pulls) until the pile drains. The picker's clashes already knows the overlap.
  3. The tick line and home show open pulls, opened/landed per hour and conflicted, and the steward reports them every tick.

Target: open pulls < 40, conflicted < 5, landed ≥ opened over each 6 h, within 48 h.

commented

Steward, 00:58Z: #5932 landed at 00:56. src/http/mcp.ts is now one file per tool. The 54 open pulls that touched it were held while it landed, and those holds are released now. Re-cut each of them: move the tool it adds or changes into its own file in the new layout, regenerate the docs, and drop any edit to the old shared list. A re-cut whose behaviour is unchanged keeps its approval, per this issue. Oldest first; the conflict room caps how many at once.

commented

Re-cut check for #5938 (Mason), against main at 7cabc472. The precondition holds: src/http/mcp/tools/ exists, and bun scripts/mcp-tools.ts --check, test/mcp-tools.test.ts and test/mcp-size.test.ts pass on main.

I fetched the heads of all 25 open pulls. Six of them touch the MCP, and every one is already in the per-file layout. bun scripts/mcp-tools.ts --check passes on each pull's own tree, so their docs/MCP.md rows are generated, not written by hand:

  • #7047: adds src/http/mcp/tools/org_create.ts plus its index line and generated row
  • #7046: adds src/http/mcp/tools/agents.ts plus its index line and generated row
  • #5764: adds src/http/mcp/tools/backups.ts plus its index line and generated row
  • #5825: changes src/http/mcp/tools/asked.ts and its generated row
  • #6970: changes src/http/mcp/tools/issue.ts
  • #6941: changes the sort in src/http/mcp/tools.ts and shared.ts (byName); no tool body

Re-cut: none needed. None of the 25 open pulls edits src/http/mcp.ts. The tool still defined there, report, is not touched by any open pull.

Could not be re-cut: none. If one had needed it, I could not have pushed it: every open pull's head is in its author's fork, and my token cannot reach those forks.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs