Skip to content

ci: enforce every byte budget on pull requests and keep raises out of feature changes - #1639

Merged
trueadm merged 13 commits into
mainfrom
ci/enforce-size-budgets
Oct 3, 2026
Merged

trueadm merged 13 commits into
mainfrom
ci/enforce-size-budgets

Conversation

@trueadm

@trueadm trueadm commented Oct 3, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Makes every committed byte budget a gate on every pull request, and keeps budget raises out of feature changes. This addresses review finding A4 ("size gating is effectively off") plus the binding-heavy bench row from F4.

Depends on #1638, which re-sets every budget to measured + 32 B for raw and gzip, and measured + 256 B for brotli. This branch carries that commit so its budget step can pass. One check is expected to fail until #1638 merges: the new lint step "Check that byte budget raises land alone", because this branch both raises budgets (via #1638's commit) and changes other files. That failure is the rule working. Once #1638 merges and main is merged in here, the raise is in the base and the step passes.

Changes

  • Every budget enforced in PR CI. Test shard 1/4's three bundle steps become one, "Verify every bundle budget":
    • run-minimal.mjs --budgets checks all 35 reachability builds; before, it checked 5 scenarios.
    • run.mjs --budgets octane-tsrx octane-jsx checks every complete Octane application.
    • The behavior-only and Apollo tree-shaking assertions still run, because every reachability build executes its gates.
    • The step costs about 75 s of build time.
  • Recording budgets.
    • Both runners gain --write-budgets, which ratchets each metric of what they built and leaves other budgets untouched. A metric drops to measured + 32 B (raw and gzip) or measured + 256 B (brotli) when that is lower, stays where the measurement still fits, and rises only when it is breached. So rewriting after a change that saved bytes never produces a raise, and a raise only ever comes from a real breach.
    • Brotli gets more headroom because it is not monotonic in code size. perf(compiler): shrink plain-module hook boundaries and inline memo lowering #1634 strictly removes code yet raises brotli by up to 120 B on three rows. Raw and gzip are the growth gate.
    • run.mjs gains positional target selection and --budgets.
    • The shared ratchetBudget lives in minimal-gates.mjs, with tests.
  • Raises land alone. benchmarks/bundle-size/budget-raises.mjs runs in lint checks.
    • It fails when a change raises a value in minimal-budgets.json, app-budgets.json or jsx-budgets.json and also changes any file that is not a budget file or prose.
    • Lowering budgets, or adding one for a new scenario, is always allowed.
    • Pull requests compare against the merge commit's first parent (HEAD^1); pushes compare against the previous commit.
  • Binding-heavy application row.
    • benchmarks/bundle-size/apps/bindings/octane-tsrx is a settings app built from @octanejs/radix, base-ui, aria (+ aria/stately), mantine-hooks, usehooks-ts, floating-ui and motion, all existing deps of the bundle-size package.
    • Bindings ship source, so the app's production build compiles them with the Octane compiler, and bindings_app_* moves with compiler output for plain .ts hooks. fix(compiler): inline plain-module memos beside parent-printed syntax #1577's +14.5 KB gz across 125 binding modules was invisible to every existing row.
    • It measures 122,497 B gz app + 119,125 B gz framework on main.
    • It builds and renders: loaded in a browser, no console errors; tabs, aria useButton and usehooks-ts useStep interactions work.
    • Measured against this row, the "declare plain-hook slot constants" session's pending F3+F4 change shrinks bindings_app by 773 B gz.
  • Weekly guards. ratios.json gains guards for the 9 bindings_* ops and the 6 Apollo reachability builds, which had none. Notes no longer claim 32-byte alignment.
  • Docs. CONTRIBUTING.md ("Size budgets"), the performance-audit skill (.rulesync source plus generated copies) and benchmarks/README.md (new "Size budgets" section) describe the policy and commands.

Validation

  • node benchmarks/bundle-size/run-minimal.mjs --budgets and node benchmarks/bundle-size/run.mjs --budgets octane-tsrx octane-jsx pass on main 11a9da935a with ci(bench): re-set every byte budget to measured + 32 bytes #1638's values.
  • The gate caught a real change locally: reformatting the bindings app's .tsrx moved its brotli by 72 B and --budgets failed until the values were re-recorded.
  • node --test scripts/ci-workflow.test.mjs benchmarks/bundle-size/minimal-gates.test.mjs benchmarks/bundle-size/budget-raises.test.mjs: 82/82 pass.
  • pnpm sync, pnpm rules:check, pnpm context:budget:check, and pnpm format:files:check on changed files.
  • pnpm format:check, pnpm typecheck, pnpm test: left to CI.

Risk / follow-ups

  • Any open PR that grows a bundle by more than 32 B fails once this lands. That is the point, and the failure message names the commands and the policy.
  • Sessions that lower budgets in their own PRs (H1 perf(hydration): keep the binding-marker validator out of client-only bundles #1637, A2, A1) should re-cut to measured + 32 with --write-budgets after this lands.
  • The PR-bench report fails on a budget breach too, via the separate PR-bench PR.

Provenance

  • An agent produced this diff (agent-authored)

🤖 Generated with Claude Code


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.


Note

Medium Risk
Changes CI merge gates and will fail open PRs that grow bundles by more than 32 raw/gzip bytes; policy is documented but adoption cost is real for in-flight work.

Overview
Turns all committed bundle byte budgets into pull-request gates and formalizes how budgets move up or down.

CI replaces three partial bundle checks with one step that runs run-minimal.mjs --budgets (every reachability scenario) and run.mjs --budgets octane-tsrx octane-jsx (every complete Octane app). Reachability builds still run behavior and Apollo tree-shaking gates as part of that suite. Lint adds budget-raises.mjs, which fails if any budget number increases alongside changes outside budget JSON or markdown prose.

Harness adds shared ratchetBudget (measured + 32 B raw/gzip, + 256 B brotli), --write-budgets on both runners, and --budgets enforcement on run.mjs. New binding-heavy TSRX app under benchmarks/bundle-size/apps/bindings exercises Radix, Base UI, Aria, Mantine hooks, usehooks-ts, floating-ui, and Motion so compiler output for plain .ts binding hooks is capped via bindings_* ops and app-budgets.json. Weekly ratios.json picks up those ops plus Apollo Client reachability budgets.

Docs (CONTRIBUTING, benchmarks README, performance-audit skills) describe the ratchet policy and commands.

Reviewed by Cursor Bugbot for commit f6c9eb7. Bugbot is set up for automated code reviews on this repo. Configure here.

trueadm and others added 2 commits October 3, 2026 08:38
Every reachability scenario (minimal-budgets.json) and every complete Octane
application (app-budgets.json, jsx-budgets.json) now has a budget of exactly
its production bytes on main plus 32, for raw, gzip and brotli.

Twenty-one budgets had been exceeded with no pull request failing, because pull
request CI enforced only five scenarios. Others had 4-30% slack that no change
could breach. As ratchets, each budget now fails on more than 32 bytes of growth
once CI enforces all of them (the follow-up pull request), and a raise lands on
its own with the bytes and the reason, as this one does.

Measured on main 11a9da9 with Node 24. Local and CI reachability bytes
matched exactly on all 105 values compared.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
… feature changes

PR CI now checks every committed byte budget, in one step in test shard 1/4:
`run-minimal.mjs --budgets` covers all 35 public-import reachability builds, and
`run.mjs --budgets octane-tsrx octane-jsx` covers every complete Octane
application. Before this, PR CI enforced five scenarios. Twenty-one budgets had
been exceeded on main with no pull request failing. These builds also run each
scenario's executable and reachability gates, including the behavior-only and
Apollo tree-shaking checks that had their own steps.

- run-minimal.mjs and run.mjs gain `--write-budgets`, which records measured +
  32 bytes for what they built. run.mjs also gains target selection and
  `--budgets`.
- A new lint step, benchmarks/bundle-size/budget-raises.mjs, fails a change
  that raises any committed budget while also changing anything other than
  budget files and prose. It compares a pull request with its merge commit's
  first parent, and a push with the previous commit. Feature changes may lower
  budgets, never raise them.
- bundle-size gains an Octane-only bindings application that renders Radix,
  Base UI, React Aria, Mantine hooks, usehooks-ts, Floating UI and Motion. The
  bindings ship source, so its `bindings_app_*` bytes move with compiler output
  for plain `.ts` binding hooks, which no other row contained.
- The weekly guards cover the bindings set and the Apollo reachability
  scenarios, which had no guards.
- CONTRIBUTING.md, the performance-audit skill and the benchmarks README
  document the policy and the commands.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@github-actions github-actions Bot added agent-authored Diff or issue body substantially produced by an AI agent ci PR: CI or build pipeline labels Oct 3, 2026
@github-actions
github-actions Bot marked this pull request as draft October 3, 2026 07:40
@github-actions

github-actions Bot commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor

Benchmark report

🟢 No budget breaches, no added work, and no timing changes beyond ±3%.

Compares d826c3e09, the merge commit's first parent with b352632f0 on the same runner. A byte value over its committed budget or any increase in a js-framework work counter fails this check. Wall time is a report: base and head samples alternate in one browser, and an operation is called slower or faster only when the 95% confidence interval of its ratio excludes ±3%. Workflow run

js-framework: 1k/10k row operations

target operation base ms head ms head/base 95% CI
octane-tsrx select_lots 0.006 0.005 −6.2% −6.9% … −5.7% 🟢 faster
All 20 timed operations (19 without a verdict)
target operation base ms head ms head/base 95% CI
octane-tsrx run 2.808 2.817 ±0.0% −3.2% … +0.0% ⚪ within noise
octane-tsrx replace 5.933 5.900 −1.7% −4.7% … +0.7% ⚪ within noise
octane-tsrx add 2.392 2.333 −3.8% −4.0% … ±0.0% ⚪ within noise
octane-tsrx update 0.135 0.135 −0.2% −1.7% … +0.8% ⚪ within noise
octane-tsrx select 0.005 0.005 +0.0% −1.2% … +1.1% ⚪ within noise
octane-tsrx swap 0.033 0.033 +0.7% +0.7% … +2.2% ⚪ within noise
octane-tsrx remove 0.017 0.017 −2.4% −3.5% … −0.4% ⚪ within noise
octane-tsrx runlots 24.783 23.933 −2.0% −4.2% … +4.9% ⚪ within noise
octane-tsrx select_lots 0.006 0.005 −6.2% −6.9% … −5.7% 🟢 faster
octane-tsrx clear 38.425 39.550 +1.2% −0.6% … +2.9% ⚪ within noise
octane-jsx run 3.233 3.275 −1.3% −3.1% … +3.1% ⚪ within noise
octane-jsx replace 5.858 6.067 +3.3% −3.2% … +6.9% ⚪ within noise
octane-jsx add 3.183 3.117 −0.0% −3.1% … ±0.0% ⚪ within noise
octane-jsx update 0.241 0.242 −0.3% −0.7% … +2.1% ⚪ within noise
octane-jsx select 0.126 0.125 +1.2% +0.3% … +2.2% ⚪ within noise
octane-jsx swap 0.220 0.229 +0.6% +0.0% … +1.2% ⚪ within noise
octane-jsx remove 0.179 0.169 +0.6% −0.9% … +1.5% ⚪ within noise
octane-jsx runlots 29.183 29.242 −1.1% −3.0% … +3.0% ⚪ within noise
octane-jsx select_lots 1.374 1.408 −0.6% −2.9% … +2.1% ⚪ within noise
octane-jsx clear 45.717 46.550 −0.1% −2.8% … +2.6% ⚪ within noise

All 64 work counters are unchanged.

Application bundle size (bytes)

target metric base head Δ
octane-tsrx bindings_js_raw – 718,810 – 🆕
octane-tsrx bindings_js_gzip – 240,396 – 🆕
octane-tsrx bindings_js_brotli – 204,641 – 🆕
octane-tsrx bindings_app_raw – 355,921 – 🆕
octane-tsrx bindings_app_gzip – 121,717 – 🆕
octane-tsrx bindings_app_brotli – 101,739 – 🆕
octane-tsrx bindings_fw_raw – 362,889 – 🆕
octane-tsrx bindings_fw_gzip – 118,679 – 🆕
octane-tsrx bindings_fw_brotli – 102,902 – 🆕

45 other measured values are unchanged.

Public-import reachability bundles (bytes)

No changes across 105 measured values.

trueadm and others added 2 commits October 3, 2026 08:48
Brotli is not monotonic in code size. #1634 removes code and shrinks raw and
gzip on every reachability row, yet raises brotli on three: +120 B on
binding-apollo-client-vite and +28/+18 B on the usehooks-ts rows. The two
changes that cause the apollo-vite rise each move brotli by single or double
digits on their own; only their combination gives +120. A measured + 32 brotli
budget would fail a change that strictly removes code, and under the
budget-raise rule that change would need a separate raise.

Raw and gzip stay at measured + 32 and remain the growth gate. Brotli becomes
measured + 256, about twice the largest swing observed, so it still catches
real compressed growth without blocking reductions.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Brotli is not monotonic in code size. #1634 removes code and shrinks raw and
gzip on every reachability row, yet raises brotli by up to 120 B, so a measured
+ 32 brotli budget would fail a pure reduction and force a raise. Budgets keep
32 bytes of headroom for raw and gzip, which remain the growth gate, and get
256 for brotli: `ratchetBudget` writes that, and the docs say which metric
judges growth. The bindings application's brotli budgets move with the rest.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

@cursor cursor Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Autofix Details

Bugbot Autofix prepared a fix for the issue found in the latest run.

  • ✅ Fixed: Brotli raises fail isolation gate
    • Made findBudgetRaises gate only on raw and gzip leaves (via a GATED_FORMATS set), excluding brotli which is non-monotonic and has intentionally wide 256-byte headroom, so brotli increases no longer trigger the isolation rule that requires raises to land alone.

Create PR

Or push these changes by commenting:

@cursor push d3170d3811
Preview (d3170d3811)
diff --git a/benchmarks/bundle-size/budget-raises.mjs b/benchmarks/bundle-size/budget-raises.mjs
--- a/benchmarks/bundle-size/budget-raises.mjs
+++ b/benchmarks/bundle-size/budget-raises.mjs
@@ -20,12 +20,17 @@
 ];
 const PROSE = /\.mdx?$/;
 
+// Brotli is non-monotonic in code size (a strict removal can raise brotli on
+// some rows), so only raw and gzip growth triggers the isolation rule.
+const GATED_FORMATS = new Set(['raw', 'gzip']);
+
 // Every numeric leaf that exists on both sides and grew, as `file: a.b.c`.
+// Only leaves whose immediate key is in GATED_FORMATS count as raises.
 export function findBudgetRaises(file, before, after) {
 	const raises = [];
 	const walk = (left, right, trail) => {
 		if (typeof right === 'number') {
-			if (typeof left === 'number' && right > left) {
+			if (typeof left === 'number' && right > left && GATED_FORMATS.has(trail[trail.length - 1])) {
 				raises.push({ budget: `${file}: ${trail.join('.')}`, before: left, after: right });
 			}
 			return;

diff --git a/benchmarks/bundle-size/budget-raises.test.mjs b/benchmarks/bundle-size/budget-raises.test.mjs
--- a/benchmarks/bundle-size/budget-raises.test.mjs
+++ b/benchmarks/bundle-size/budget-raises.test.mjs
@@ -5,13 +5,13 @@
 const MINIMAL = 'benchmarks/bundle-size/minimal-budgets.json';
 const APP = 'benchmarks/bundle-size/app-budgets.json';
 
-test('only grown values that exist on both sides are raises', () => {
+test('only grown raw and gzip values that exist on both sides are raises', () => {
 	const before = {
 		context: { raw: 100, gzip: 50, brotli: 40 },
 		rows: { app: { gzip: 10 }, total: { gzip: 20 } },
 	};
 	const after = {
-		context: { raw: 90, gzip: 51, brotli: 40 },
+		context: { raw: 90, gzip: 51, brotli: 45 },
 		rows: { app: { gzip: 10 }, total: { gzip: 21 } },
 		added: { raw: 999, gzip: 999, brotli: 999 },
 	};
@@ -22,6 +22,12 @@
 	assert.deepEqual(findBudgetRaises(MINIMAL, null, after), []);
 });
 
+test('brotli raises are excluded because brotli is non-monotonic', () => {
+	const before = { context: { raw: 100, gzip: 50, brotli: 40 } };
+	const after = { context: { raw: 100, gzip: 50, brotli: 60 } };
+	assert.deepEqual(findBudgetRaises(MINIMAL, before, after), []);
+});
+
 test('a raise alone, with prose, is allowed', () => {
 	const raises = [{ budget: `${MINIMAL}: context.gzip`, before: 50, after: 51 }];
 	assert.deepEqual(

You can send follow-ups to the cloud agent here.

Comment thread benchmarks/bundle-size/app-budgets.json Resolved
# Conflicts:
#	benchmarks/bundle-size/minimal-budgets.json

@cursor cursor Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix prepared a fix for the issue found in the latest run.

  • ✅ Fixed: Brotli raises fail isolation gate
    • Excluded brotli keys from the findBudgetRaises walk so only raw and gzip (the actual growth gate) can trigger the isolation check, matching the documented policy that brotli is not monotonic and not part of the growth gate.

Create PR

Or push these changes by commenting:

@cursor push df7b7d7912
Preview (df7b7d7912)
diff --git a/benchmarks/bundle-size/budget-raises.mjs b/benchmarks/bundle-size/budget-raises.mjs
--- a/benchmarks/bundle-size/budget-raises.mjs
+++ b/benchmarks/bundle-size/budget-raises.mjs
@@ -20,7 +20,9 @@
 ];
 const PROSE = /\.mdx?$/;
 
-// Every numeric leaf that exists on both sides and grew, as `file: a.b.c`.
+// Every non-brotli numeric leaf that exists on both sides and grew, as
+// `file: a.b.c`. Brotli is excluded because it is not monotonic in code size
+// (removing code can raise brotli), so it is not part of the growth gate.
 export function findBudgetRaises(file, before, after) {
 	const raises = [];
 	const walk = (left, right, trail) => {
@@ -31,7 +33,10 @@
 			return;
 		}
 		if (right && typeof right === 'object' && left && typeof left === 'object') {
-			for (const key of Object.keys(right)) walk(left[key], right[key], [...trail, key]);
+			for (const key of Object.keys(right)) {
+				if (key === 'brotli') continue;
+				walk(left[key], right[key], [...trail, key]);
+			}
 		}
 	};
 	walk(before, after, []);

diff --git a/benchmarks/bundle-size/budget-raises.test.mjs b/benchmarks/bundle-size/budget-raises.test.mjs
--- a/benchmarks/bundle-size/budget-raises.test.mjs
+++ b/benchmarks/bundle-size/budget-raises.test.mjs
@@ -22,6 +22,12 @@
 	assert.deepEqual(findBudgetRaises(MINIMAL, null, after), []);
 });
 
+test('brotli growth is excluded from raises because it is not monotonic', () => {
+	const before = { context: { raw: 100, gzip: 50, brotli: 40 } };
+	const after = { context: { raw: 100, gzip: 50, brotli: 296 } };
+	assert.deepEqual(findBudgetRaises(MINIMAL, before, after), []);
+});
+
 test('a raise alone, with prose, is allowed', () => {
 	const raises = [{ budget: `${MINIMAL}: context.gzip`, before: 50, after: 51 }];
 	assert.deepEqual(

You can send follow-ups to the cloud agent here.

Reviewed by Cursor Bugbot for commit 6c52af2. Configure here.

…d metric

`--write-budgets` set every metric to measured + headroom. After a change that
saved bytes, that could lift a brotli budget, since brotli can grow when code is
removed, so the change would trip the budget-raise gate it was meant to
satisfy. Each metric now drops to measured + headroom when that is lower, stays
where the measurement still fits, and rises only when the measurement exceeds
it. A raise therefore comes only from a real breach, and the gate stays strict
for all three metrics. Rewriting unchanged bytes is a no-op.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@trueadm
trueadm marked this pull request as ready for review October 3, 2026 10:25
trueadm and others added 2 commits October 3, 2026 12:05
# Conflicts:
#	package.json
Main moved while budgets were unenforced: 70 values shrank and are lowered; 30
grew past the reset values and are raised to measured + headroom by the
ratchet writer (largest: hydrate-root +88 gzip, octane-jsx rows framework +100
gzip). The same values go to the budget pull request, #1638.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
trueadm added a commit that referenced this pull request Oct 3, 2026
Main moved while budgets were unenforced: 70 values shrank and are lowered to
measured + headroom; 30 grew past the reset values and are raised to measured
+ headroom (largest: hydrate-root +88 gzip, octane-jsx rows framework +100
gzip). Identical to the values in #1639.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
trueadm and others added 2 commits October 3, 2026 12:09
# Conflicts:
#	package.json
Main grew again while budgets were unenforced: most bundles gained 37-68 raw
bytes, and the todo framework gained 34 B gzip. The ratchet writer raises the
breached metrics (cli-spa-starter tripped this branch's gate by 13 raw bytes)
and lowers the ones that shrank. The same values go to #1638.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
trueadm added a commit that referenced this pull request Oct 3, 2026
Main grew again while budgets were unenforced (most bundles +37-68 raw bytes,
todo framework +34 B gzip). Breached metrics are raised to measured + headroom,
shrunk ones lowered. Identical to the values in #1639.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@vercel

vercel Bot commented Oct 3, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

2 Skipped Deployments
Project Deployment Actions Updated
octane-website Skipped Skipped Oct 3, 2026 1:26pm UTC
octane-website-mcp Skipped Skipped Oct 3, 2026 1:26pm UTC

Request Review

@vercel
vercel Bot temporarily deployed to Preview – octane-website-mcp October 3, 2026 13:26 Inactive
@vercel
vercel Bot temporarily deployed to Preview – octane-website October 3, 2026 13:26 Inactive
trueadm added a commit that referenced this pull request Oct 3, 2026
* ci(bench): re-set every byte budget to measured + 32 bytes

Every reachability scenario (minimal-budgets.json) and every complete Octane
application (app-budgets.json, jsx-budgets.json) now has a budget of exactly
its production bytes on main plus 32, for raw, gzip and brotli.

Twenty-one budgets had been exceeded with no pull request failing, because pull
request CI enforced only five scenarios. Others had 4-30% slack that no change
could breach. As ratchets, each budget now fails on more than 32 bytes of growth
once CI enforces all of them (the follow-up pull request), and a raise lands on
its own with the bytes and the reason, as this one does.

Measured on main 11a9da9 with Node 24. Local and CI reachability bytes
matched exactly on all 105 values compared.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* ci(bench): give brotli budgets 256 bytes of headroom

Brotli is not monotonic in code size. #1634 removes code and shrinks raw and
gzip on every reachability row, yet raises brotli on three: +120 B on
binding-apollo-client-vite and +28/+18 B on the usehooks-ts rows. The two
changes that cause the apollo-vite rise each move brotli by single or double
digits on their own; only their combination gives +120. A measured + 32 brotli
budget would fail a change that strictly removes code, and under the
budget-raise rule that change would need a separate raise.

Raw and gzip stay at measured + 32 and remain the growth gate. Brotli becomes
measured + 256, about twice the largest swing observed, so it still catches
real compressed growth without blocking reductions.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* ci(bench): re-measure budgets on main bc6761f

Main moved while budgets were unenforced: 70 values shrank and are lowered to
measured + headroom; 30 grew past the reset values and are raised to measured
+ headroom (largest: hydrate-root +88 gzip, octane-jsx rows framework +100
gzip). Identical to the values in #1639.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

* ci(bench): re-measure budgets on main ac729dc

Main grew again while budgets were unenforced (most bundles +37-68 raw bytes,
todo framework +34 B gzip). Breached metrics are raised to measured + headroom,
shrunk ones lowered. Identical to the values in #1639.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
@trueadm
trueadm merged commit 4f4b9db into main Oct 3, 2026
30 checks passed
@trueadm
trueadm deleted the ci/enforce-size-budgets branch October 3, 2026 17:40
trueadm added a commit that referenced this pull request Oct 3, 2026
…nd warm-plan perf PRs (#1687)

Three open runtime perf pull requests fail the PR bench byte gate on main
12c32ec, and landing any two of them stacks past the 32-byte headroom:

- #1664 (de-opt survivor fast path): +809 raw / +290 gzip
  in the bindings app framework chunk, which #1676 did not raise because
  #1639 added that budget key first; +20 raw in every compiled-only app.
- #1666 (warm-plan length guard): +17 raw in every client
  bundle, two `!==` guards.
- #1663 (scoped-value read-once): +2 raw / +30-70 gzip in
  descriptor-renderer bundles, a compression shift from the restructured
  childSlot reads.

Main had already spent part of the headroom: bindings framework gzip
measured exactly its budget and deferred-hydration raw had 8 bytes left.

Each budget is set to the largest value measured across each PR merged
alone with main and all of them merged together (plus #1665, which moves
none of these values), plus 32 for raw and gzip and 256 for brotli. Only
values one of those trees exceeds change.

Co-authored-by: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agent-authored Diff or issue body substantially produced by an AI agent ci PR: CI or build pipeline

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant