Skip to content

Raise the startup bundle budget to where main actually is - #10702

Merged
danielhanchen merged 1 commit into
mainfrom
ci/raise-startup-bundle-budget
Sep 10, 2026
Merged

danielhanchen merged 1 commit into
mainfrom
ci/raise-startup-bundle-budget

Conversation

@danielhanchen

Copy link
Copy Markdown
Member

Frontend build + bundle sanity has been red on main since it crossed the 1,582.0 KB eager-transfer ceiling:

over the startup budget: transfer 1585.6 KB > 1582.0 KB
Something is now imported statically that the first screen does not need.

It is not one change that did it, so I measured rather than guessed. Four builds on one machine, same toolchain, transfer / raw / chunks:

commit what it is transfer raw chunks
3f2c89537 #10629's parent 1,574.7 KB 5,260.1 KB 91
e3e457a7d #10629, eager Settings 1,579.9 KB 5,288.8 KB 82
19c86b3cc last green Frontend CI 1,576.5 KB 5,267.6 KB 91
7436c103e main 1,585.6 KB 5,306.4 KB 82

#10629 is the largest single contributor at +5.2 KB. It statically imports SettingsDialog and FloatingMonitor:

+import { FloatingMonitor } from "@/components/floating-monitor";
+import { SettingsDialog } from "./settings-dialog";

which is the fix it shipped, and which is what folds nine chunks into the eager graph and takes settings-*.js from 158.0 KB raw to 208.2 KB. Making Settings lazy again would undo that PR rather than fix anything.

It landed with 2.1 KB of headroom left. The commits after it spent it, none of them individually over the line.

So this takes the other branch the guard's own message offers: raise the budget with the measurement. 1,645,000 bytes leaves 20.9 KB spare, about the headroom the previous raise took. Raw is untouched at 5,500,000, still 64.7 KB clear at 5,306.4 KB.

$ npm run build && npm run bundle:check
eager startup JS: 5306.4 KB raw, 1585.6 KB transfer, 82 chunks
within budget (20.9 KB transfer, 64.7 KB raw to spare)

tests/bundle-budget-closure.test.ts passes 32/32.

The measurements are in the comment above BUDGET as well, so the next person to look at this does not have to rebuild four commits to find out where the bytes went.

Frontend CI has been red since main crossed the 1,582.0 KB eager-transfer
ceiling, and it is not one change that did it. Four builds on one machine, same
toolchain, transfer / raw / chunks:

  3f2c895  #10629's parent          1,574.7 / 5,260.1 / 91
  e3e457a  #10629 eager Settings    1,579.9 / 5,288.8 / 82
  19c86b3  last green Frontend CI   1,576.5 / 5,267.6 / 91
  7436c10  main                     1,585.6 / 5,306.4 / 82

#10629 is the largest single contributor at +5.2 KB. It statically imports
SettingsDialog and FloatingMonitor, which is the fix it shipped, and which is
what folds nine chunks into the eager graph and takes settings-*.js from
158.0 KB raw to 208.2 KB. Making Settings lazy again would undo that PR rather
than fix anything. It landed with 2.1 KB of headroom left; the commits after it
spent it.

So this is the other branch the guard's own message offers: raise the budget with
the measurement. 1,645,000 bytes leaves 20.9 KB spare, about the headroom the
previous raise took. Raw is untouched at 5,500,000, still 64.7 KB clear.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 10, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-10T06:47:22.339267Z 03f2932 PR opened
🔒 Security Review ✅ Completed 2026-09-10T06:48:39.969056Z 03f2932 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@danielhanchen
danielhanchen merged commit b50d53d into main Sep 10, 2026
36 of 38 checks passed
@danielhanchen
danielhanchen deleted the ci/raise-startup-bundle-budget branch September 10, 2026 07:00
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