Skip to content

fix(octane): commit the pending cue apart from its component's transition (#1864) - #1888

Merged
trueadm merged 8 commits into
mainfrom
fix/transition-cue-split
Oct 8, 2026
Merged

trueadm merged 8 commits into
mainfrom
fix/transition-cue-split

Conversation

@trueadm

@trueadm trueadm commented Oct 8, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Closes the G1 gap that #1873 documented for #1864. When the component that raises isPending also holds its transition's own update, the pending cue now commits with the previous state. The transition renders in its posted task, as React renders isPending in an urgent lane before the transition lane. This is the canonical useTransition pattern, used by the docs' ProjectTabs example and the playground's Sort button.

Refs #1864 (does not close it).

Why

Octane keeps one live tree, and the transition's cell was already written when the cue rendered. So the cue and the transition rendered together in the click's microtask flush, and the browser could not paint "Sorting…" until the whole transition render had finished. jsdom commit log for const [isPending, start] = useTransition(); const [tab, setTab] = useState('a'), clicking start(() => setTab('b')) with a MessageChannel marker posted first:

Commits
main a idle, b pending, b idle, task
this PR a idle, a pending, task, b pending, b idle
React 19.2.7 a idle, a pending, task, b idle

The frames a browser can paint are the same as React's: a pending at the first task boundary and b idle at the next. The remaining difference is isPending's falling edge. It still commits right after the transition render, in the same task and before the next frame, as it already does on main when the cue and the transition live in different components (see Risk).

Changes

  • upgradeTransitionBlock: outside a flush, a pending cue never takes transition work out of the task queue.
    • A transition update flushed for a block that is already queued for its cue (flushTransitionActionBatch) also waits in TRANSITION_QUEUE.
    • A cue for a block whose transition is already waiting also queues the block for the microtask flush.
    • The block is then queued in both places.
  • drainQueue → splitTransitionCue: the microtask flush renders such a block's cue alone, at urgent priority, over its committed cells (renderTransitionCue). It reuses the exposure an urgent ancestor already applies to a child with a queued transition (beginUrgentTransitionRender), then leaves the block pending for the task.
    • The combined render (today's behavior) is kept for transition work without staged hook state, inside a Suspense/Activity boundary that owns the render, or with a pending root request.
    • An urgent ancestor that already rendered the cue spares the block's own queue entry a second render.
  • View Transitions: a split cue counts as urgent work in queueAllTransition and shouldClearTypesAfterFlush. It no longer starts a View Transition of its own, which the transition's real animation would then wait behind. It also no longer clears the transition's addTransitionType types.
  • beginUrgentTransitionRender fixes:
    • It no longer reverts a hook cell whose queue a render already consumed. That could flash a committed transition value back (regression test below).
    • It no longer allocates a slot Map, and endUrgentTransitionRender no longer allocates a predicate closure, per call.
  • Retained plain cells (Bugbot, fixed in ee54d6151b). FLUSHED_TRANSITION_UPDATES stays retained while any block waits for the task. When a block that is not queued is scheduled at transition priority, a render has consumed every update retained for it, so queueTransitionBlock marks those entries rendered, and the cue exposure skips them. Without this, a later split cue flashed a committed useDeferredValue or useLinkedState value back to its base. A hold clears the mark when it takes the entries.
  • Contract:
  • benchmarks/transition-hooks: the cycle, updater and held controls pinned the old order (cue with the new value). They now expect the cue with the committed value. Work model and README updated (see Performance).
  • Changeset: octane patch.

Validation

  • packages/octane/tests/transition-flush-task.test.ts (--project octane): 33/33, plus fix: publish Action cues before native transition capture #1872's transition-task.test.ts 16/16. 10 of the 16 new tests fail on main:
    • the canonical case, both arrival orders, several transitions on one cell;
    • a sibling sharing the transition, an urgent update rebasing during the wait;
    • a transition-committed value kept by a later cue (also fails with only the beginUrgentTransitionRender fix reverted: the cue shows a1 instead of b1);
    • a committed deferred value kept by a later cue (also fails with only the rendered marking disabled: the cue shows b/a/x instead of b/b/x);
    • useOptimistic, unmount before the task, and View Transition plus types (each VT routing change reverted on its own fails it too).
    • Six pin neighbouring behavior that must not move and pass on both: Suspense hold after the cue, async Action staging, flushSync, awaited act(), and controlled input.
    • fix: publish Action cues before native transition capture #1872's same-root "captures explicit transition state alongside an Action cue" cases pinned the old order, with the cue and the same component's transition state captured together in the microtask flush. They now assert the separate-root order: the cue commits without a capture, and the state is captured in its task (0fefe82260).
  • New Chromium test packages/octane/tests/browser/transition-cue (--project octane-events-browser). It runs the same .tsrx fixture under Octane and React 19.2.7 (compiled with @tsrx/react): the Sort pattern, with isPending and sorted in one component and a memoized slow list. It asserts the first commit is Sorting… with the unsorted list, and that the click's Event Timing latency is under half the list's cost. It passes for both runtimes and fails on main (Sorting… commits with sorted: true).
  • pnpm typecheck:files on the changed TS/TSRX files; pnpm format:files on changed files; pnpm sync clean.
  • pnpm test, full pnpm typecheck, pnpm format:check: left to CI (repo rule: no wide local runs while parallel sessions share the machine).

Chromium Event Timing (Sort pattern, memoized 40 ms list, 5 clicks, Event Timing ≥ 16 ms)

CPU main this PR React 19.2.7
1× 5/5 slow clicks: 64, 40, 40, 40, 40 ms 1/5: 24 ms (first, cold) 1/5: 24 ms (first, cold)
4× 5/5: 80, 40, 40, 40, 40 ms 1/5: 40 ms (first, cold) 1/5: 40 ms (first, cold)

Commit sequence for one click, same page: React Sort → Sorting…/unsorted → Unsort/sorted. This PR: Sort → Sorting…/unsorted → (task) Sorting…/sorted → Unsort/sorted. The last two commits share one task. The slow list renders once, in the task, as in React.

Performance

transition-hooks (OCTANE_TRANSITION_TIMING=0 node benchmarks/bench.mjs --ratios transition-hooks): all 42 guards pass with the updated work model. Creation events per 64 cycles against 823e100dd:

Scenario renders functions / arrays / objects / constructors Map.get
cycle 128 → 192 128/1,728/707/192 → 256/2,624/1,155/320 640 → 896
updater 128 → 192 64/1,728/704/192 → 192/2,624/1,152/320 640 → 896
held 256 → 320 640/4,480/1,344/834 → 768/5,376/1,664/962 1,473 → 1,793
urgent 256 → 256 192/1,984/1,088/256 → 256/2,688/1,280/320 896 → 960
dispatch, bail, click unchanged unchanged unchanged
  • The extra render is the cue's own; one render of this component costs 11 arrays, 4 objects and 1 constructor (dispatch).
  • The rest is the transition's posted task and its separate flush (task closure, MessageChannel, follow-up list). main never posted a task for this pattern.
  • React also renders the cue and the transition separately. It does 2 renders where this PR does 3, because it folds the falling edge into the transition render (see Risk).

Bundle (run-minimal.mjs --budgets, run.mjs --budgets octane-tsrx octane-jsx):

js-framework: no transitions, so the transition driver is null. drainQueue makes no new call, and renderBlock is still called once per drained block through a local. Call and DOM-mutation counters should be identical; see the PR bench report.

perf-review

Scan: node scripts/perf-review-scan.mjs → 1 candidate.
Hot paths touched:

  • drainQueue: per queued block per flush, one optional-chained call only when the transition driver is installed.
  • flushTransitionActionBatch: per transition update, +1 driver call.
  • begin/endUrgentTransitionRender: per urgent render over queued transition work, now also per split cue, with fewer allocations than before.
  • queueAllTransition / shouldClearTypesAfterFlush: View Transition apps only, a predicate per transition-mode queued block while the task queue is non-empty.

scheduleRender is unchanged. No Block/Scope fields, no DOM reads, no new task poster (the existing scheduleTransitionTask → postHostTask).

# Severity Location Dimension Finding Required evidence Provided?
1 needs-evidence packages/octane/src/runtime.ts:7703 scheduling A split cue arms the microtask flush, while the transition moves to its task. Marker-task commit order; Chromium Event Timing vs React yes: jsdom marker tests, browser table above
2 note benchmarks/transition-hooks/run.mjs allocation +1 render and the task's flush per same-component transition Work-model counters with semantic controls yes: table above
3 note bundle budgets reachability ~+1.42 kB raw for apps with transitions; +~21 raw otherwise CI bench report rows budget PR + CI report

Dismissed: runtime.ts:7703 [microtask-hop]. It is the standard !scheduled-guarded flush arm, one per burst; it renders the cue once and does no per-value work.

Risk / follow-ups

  • Falling edge. isPending still falls in a commit of its own right after the transition render, in the same task, never painted. React folds it into the transition render. On main the cross-component case already works this way. Folding it needs a design for per-boundary Suspense holds in Octane's one-walk commit: a sibling that holds after the component committed "idle" would leave it wrong.
  • Pure cues (the cue's component holds no transition state) still render at transition priority. A cue in an ancestor whose re-render reaches the transition's child still renders that child's transition in the microtask flush. Pure cue flushes also remain eligible for View Transition wrapping; fix: publish Action cues before native transition capture #1872 addresses that for Action cues.
  • fix: publish Action cues before native transition capture #1872 merged first. The conflict in queueAllTransition is resolved with the split-cue check first in the loop, before fix: publish Action cues before native transition capture #1872's cue-only receipt check, which would otherwise count a split block's staged cells as work this drain renders. Both test files pass on the merge.
  • The branch contains main up to 7540c3552e. A merge with the current main (c0192ec816) is conflict-free (git merge-tree). The app's sync tool declined it until this repo's pinned git origin is confirmed, because that merge touches .claude/skills.
  • Combined render kept when the cue's block sits inside a Suspense boundary that holds a suspended transition, inside a hidden Activity, during a pending root.render, or when the waiting work is not hook state. This is documented in §Scheduler.
  • Bindings or apps that asserted the old order (the cue commit showing the new state) will see one more commit, as transition-hooks did.

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

High Risk
Changes core transition scheduling and commit ordering in runtime.ts, affecting useTransition, useOptimistic, View Transitions, and Suspense holds; extra render per transition may break tests that assumed the old cue+update flush.

Overview
Fixes #1864: when one component owns both isPending and the state its transition updates (the canonical useTransition pattern), Octane no longer commits the pending cue and the new state in the same microtask flush.

Scheduling: The pending cue now renders urgently with committed/previous hook values (renderTransitionCue, splitTransitionCue, revised upgradeTransitionBlock). The transition’s real update stays on TRANSITION_QUEUE and runs in the existing posted host task. Same idea applies to useOptimistic cues and cues that arrive while a transition is already waiting. Urgent updates, flushSync, and act() behavior is preserved; Suspense/Activity holds and non–hook transition work can still combine renders.

View Transitions: Split cues are treated as urgent—no native capture on the cue alone, and addTransitionType types wait for the transition task (queueAllTransition, shouldClearTypesAfterFlush).

Correctness: TransitionActionUpdate.rendered and beginUrgentTransitionRender fixes avoid flashing back committed or deferred values on later cues.

Validation & docs: Expanded transition-flush-task tests, new Chromium transition-cue test (Octane vs React 19.2.7, Event Timing), updated transition-hooks benchmarks/work model (+1 render per cycle in affected scenarios), and scheduler/docs/website copy for the new commit order.

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

trueadm and others added 3 commits October 8, 2026 13:17
…tion (#1864)

When the component that raises isPending also held the transition's own
update, both rendered together in the click's microtask flush: the cue showed
the new state, and the browser could not paint "pending" until the whole
transition render had finished. That is the canonical useTransition pattern
(the docs' ProjectTabs example, the playground's Sort button). React renders
isPending in an urgent lane with the previous state and the transition's
update later, in a Scheduler task.

A pending cue now never renders transition work that waits for the task. When
a transition update flushes for a block already queued for its cue
(flushTransitionActionBatch), or a cue arrives for a block whose transition is
waiting (upgradeTransitionBlock), the block is queued in both places. The
microtask drain renders only the cue (splitTransitionCue), at urgent priority
over the block's committed cells, through the exposure an urgent ancestor
already uses for a child with a queued transition, then leaves the block
pending for the transition task. Suspense holds after the cue, useOptimistic,
urgent updates during the wait (which still render the transition with them),
flushSync, act(), unmount and controlled inputs keep their behavior. A split
cue renders outside a View Transition and leaves addTransitionType types to the
transition's render.

beginUrgentTransitionRender no longer reverts a hook cell whose queue a render
already consumed, which could flash a committed transition value back, and no
longer allocates a slot index or predicate closure per call. An urgent ancestor
that already rendered a split cue spares the block's own queue entry a second
render.

Chromium Event Timing on the Sort pattern (memoized 40 ms list, 5 clicks):
main 5/5 slow clicks (40-80 ms); now 1/5 (first, cold), matching React 19.2.7.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Shard 1/4 fails its byte budgets until #1887 merges, and fail-fast then cancels
shards 2-4. This commit only lets those shards report; it is reverted before
merge, and the raise lands through #1887.

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 fix PR: bug fix labels Oct 8, 2026
@trueadm
trueadm marked this pull request as ready for review October 8, 2026 12:21

@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: Stale deferred cells revert on later cues
    • Added slot.renderTransition as a liveness marker for non-hook transition entries (mirroring the existing cell.renderTransition for hooks), set it during flushTransitionActionBatch, cleared it when useDeferredValue reads its value in a transition render and at flushWork-end, and guarded hasQueuedTransitionCells and beginUrgentTransitionRender against committed entries.

Create PR

Preview
diff --git a/packages/octane/src/runtime.ts b/packages/octane/src/runtime.ts
--- a/packages/octane/src/runtime.ts
+++ b/packages/octane/src/runtime.ts
@@ -3132,7 +3132,8 @@
 		if (!changed && !forceRender && update.previous === undefined) continue;
 		if (changed) slot.value = value;
 		if (update.reducer !== undefined) update.reducer.renderTransition = update;
-		if (update.state !== undefined) update.state.renderTransition = update;
+		else if (update.state !== undefined) update.state.renderTransition = update;
+		else update.slot.renderTransition = update;
 		// Queue replay can still be required after an urgent replacement already
 		// published the staged value. That bookkeeping is not a state-change cause;
 		// reducers retain their explicit forced-render cause.
@@ -3353,6 +3354,15 @@
 /** Flushed sync-transition updates retained for the drain, one group per batch. */
 let FLUSHED_TRANSITION_UPDATES: Array<Array<TransitionActionUpdate<any>>> = [];
 
+function clearNonHookRenderTransitions(): void {
+	for (const entries of FLUSHED_TRANSITION_UPDATES) {
+		for (const entry of entries) {
+			if (entry.state === undefined && entry.reducer === undefined)
+				entry.slot.renderTransition = undefined;
+		}
+	}
+}
+
 interface WarmHarvestEntry {
 	slot: HookSlot;
 	deps: any[];
@@ -7781,7 +7791,12 @@
 		for (const update of entries) {
 			if (update.block !== block || update.superseded) continue;
 			const cell = update.state ?? update.reducer;
-			if (cell === undefined || cell.renderTransition !== undefined) return true;
+			if (
+				cell !== undefined
+					? cell.renderTransition !== undefined
+					: update.slot.renderTransition !== undefined
+			)
+				return true;
 		}
 	}
 	return false;
@@ -8677,8 +8692,10 @@
 		if (
 			(clearRetainedTransitionUpdates || FLUSHED_TRANSITION_UPDATES.length > 0) &&
 			TRANSITION_QUEUE.length === 0
-		)
+		) {
+			clearNonHookRenderTransitions();
 			FLUSHED_TRANSITION_UPDATES.length = 0;
+		}
 		if (typeof __OCTANE_PROFILE_ENABLED__ !== 'undefined' && __OCTANE_PROFILE_ENABLED__)
 			__devtoolsNotifyFlush();
 		if (clearViewTransitionTypes) viewTransitionDriver!.clearTypes();
@@ -11944,13 +11961,22 @@
 	for (const entries of FLUSHED_TRANSITION_UPDATES) {
 		for (const update of entries) {
 			if (update.block !== block || update.superseded) continue;
+			if (
+				update.state === undefined &&
+				update.reducer === undefined &&
+				update.slot.renderTransition === undefined
+			)
+				continue;
 			// A block has few staged cells, so a scan beats allocating a slot index.
 			let previous = 0;
 			while (previous < cells.length && cells[previous].update.slot !== update.slot) previous++;
 			if (previous < cells.length) {
 				// State/reducer entries retain their preceding operation chain. Plain
-				// deferred cells still need the earliest committed value below.
+				// deferred cells use the latest entry's base (the committed value before
+				// this transition, not one from an earlier committed transition).
 				cells[previous].update = update;
+				if (update.state === undefined && update.reducer === undefined)
+					cells[previous].baseValue = update.baseValue;
 			} else {
 				cells.push({
 					update,
@@ -44355,7 +44381,11 @@
 	s.next = value;
 	const wasHidden = s.wasHidden;
 	s.wasHidden = hidden;
-	if (Object.is(s.value, value)) return s.value;
+	if (Object.is(s.value, value)) {
+		if (s.renderTransition !== undefined && block.currentRenderMode === 'transition')
+			s.renderTransition = undefined;
+		return s.value;
+	}
 	// Hidden-prerender update, or the first render after a hidden→visible
 	// reveal: React treats the (re)appearing tree as a fresh mount for this
 	// hook — there is no on-screen "previous" value to defer to
@@ -44377,6 +44407,7 @@
 	// values update in the same paint.
 	if (block.currentRenderMode === 'transition') {
 		s.value = value;
+		s.renderTransition = undefined;
 		return value;
 	}
 	if (!s.scheduled && !hasHeldDeferredSwap(s)) spawnDeferredSwap(s);

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

Reviewed by Cursor Bugbot for commit fdb2de9. Configure here.

Comment thread packages/octane/src/runtime.ts Resolved
@github-actions

github-actions Bot commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

Benchmark report

  • ❌ bundle-size: 18 value(s) exceed their committed budget
  • ❌ bundle-reachability: 40 value(s) exceed their committed budget
  • 🔴 bundle-size: 21 value(s) increased within budget
  • 🔴 bundle-reachability: 30 value(s) increased within budget

Compares c0192ec81, the merge commit's first parent (main has moved 2 commit(s) past the pull request's recorded base 7540c3552) with c50935506 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

All 20 timed operations (20 without a verdict)
target operation base ms head ms head/base 95% CI
octane-tsrx run 2.767 2.683 ±0.0% −0.0% … ±0.0% ⚪ within noise
octane-tsrx replace 6.167 6.150 ±0.0% −3.6% … +1.5% ⚪ within noise
octane-tsrx add 2.617 2.658 ±0.0% −3.8% … +2.0% ⚪ within noise
octane-tsrx update 0.118 0.120 +0.3% −1.5% … +2.8% ⚪ within noise
octane-tsrx select 0.006 0.006 −0.0% −2.3% … +1.4% ⚪ within noise
octane-tsrx swap 0.037 0.037 +0.7% −0.7% … +4.0% ⚪ within noise
octane-tsrx remove 0.016 0.017 +0.1% −2.9% … +3.4% ⚪ within noise
octane-tsrx runlots 28.150 27.158 −0.4% −2.4% … +1.1% ⚪ within noise
octane-tsrx select_lots 0.006 0.006 −1.8% −3.1% … −0.3% ⚪ within noise
octane-tsrx clear 38.492 40.000 +2.6% −2.6% … +6.2% ⚪ within noise
octane-jsx run 3.917 3.900 −0.9% −2.7% … +2.6% ⚪ within noise
octane-jsx replace 7.067 6.925 ±0.0% −4.9% … +4.3% ⚪ within noise
octane-jsx add 3.458 3.325 −1.3% −2.9% … +1.5% ⚪ within noise
octane-jsx update 0.261 0.267 +0.7% −2.3% … +5.8% ⚪ within noise
octane-jsx select 0.150 0.156 −1.2% −3.5% … +0.8% ⚪ within noise
octane-jsx swap 0.239 0.240 −0.6% −3.2% … +0.9% ⚪ within noise
octane-jsx remove 0.180 0.185 +0.9% −0.6% … +4.5% ⚪ within noise
octane-jsx runlots 32.242 31.783 −2.5% −4.7% … −1.0% ⚪ within noise
octane-jsx select_lots 1.718 1.827 +0.8% −9.4% … +7.2% ⚪ within noise
octane-jsx clear 40.750 40.617 −2.5% −4.6% … +2.6% ⚪ within noise

All 64 work counters are unchanged.

Application bundle size (bytes)

❌ 18 value(s) exceed their committed budget. Reduce the growth, or raise the budget in a separate pull request that names the bytes and the reason (CONTRIBUTING.md, "Size budgets").

target metric head budget over
octane-tsrx fw_raw 106,185 106,170 +15
octane-tsrx js_raw 113,131 113,116 +15
octane-tsrx todo_fw_raw 116,920 116,906 +14
octane-tsrx todo_js_raw 121,538 121,524 +14
octane-tsrx chat_fw_raw 114,522 114,508 +14
octane-tsrx chat_fw_gzip 36,798 36,791 +7
octane-tsrx chat_js_raw 120,287 120,273 +14
octane-tsrx chat_js_gzip 39,512 39,506 +6
octane-tsrx weather_fw_raw 134,688 134,674 +14
octane-tsrx weather_js_raw 156,842 156,828 +14
octane-tsrx bindings_fw_raw 341,194 339,780 +1,414
octane-tsrx bindings_fw_gzip 109,339 108,932 +407
octane-tsrx bindings_fw_brotli 94,961 94,788 +173
octane-tsrx bindings_js_raw 688,832 687,418 +1,414
octane-tsrx bindings_js_gzip 225,006 224,599 +407
octane-tsrx bindings_js_brotli 191,175 191,021 +154
octane-jsx fw_raw 179,464 179,450 +14
octane-jsx js_raw 187,729 187,715 +14
target metric base head Δ
octane-tsrx js_raw 113,110 113,131 +21 (+0.0%) 🔴
octane-tsrx js_gzip 36,865 36,879 +14 (+0.0%) 🔴
octane-tsrx js_brotli 32,630 32,590 −40 (−0.1%) 🟢
octane-tsrx app_brotli 2,036 2,032 −4 (−0.2%) 🟢
octane-tsrx fw_raw 106,164 106,185 +21 (+0.0%) 🔴
octane-tsrx fw_gzip 34,530 34,544 +14 (+0.0%) 🔴
octane-tsrx fw_brotli 30,594 30,558 −36 (−0.1%) 🟢
octane-tsrx todo_js_raw 121,517 121,538 +21 (+0.0%) 🔴
octane-tsrx todo_js_gzip 39,656 39,674 +18 (+0.0%) 🔴
octane-tsrx todo_js_brotli 34,916 34,923 +7 (+0.0%) 🔴
octane-tsrx todo_app_brotli 1,885 1,886 +1 (+0.1%) 🔴
octane-tsrx todo_fw_raw 116,899 116,920 +21 (+0.0%) 🔴
octane-tsrx todo_fw_gzip 37,435 37,453 +18 (+0.0%) 🔴
octane-tsrx todo_fw_brotli 33,031 33,037 +6 (+0.0%) 🔴
octane-tsrx chat_js_raw 120,266 120,287 +21 (+0.0%) 🔴
octane-tsrx chat_js_gzip 39,496 39,512 +16 (+0.0%) 🔴
octane-tsrx chat_js_brotli 34,834 34,858 +24 (+0.1%) 🔴
octane-tsrx chat_app_gzip 2,715 2,714 −1 (−0.0%) 🟢
octane-tsrx chat_fw_raw 114,501 114,522 +21 (+0.0%) 🔴
octane-tsrx chat_fw_gzip 36,781 36,798 +17 (+0.0%) 🔴
octane-tsrx chat_fw_brotli 32,448 32,472 +24 (+0.1%) 🔴
octane-tsrx weather_js_raw 156,821 156,842 +21 (+0.0%) 🔴
octane-tsrx weather_js_gzip 50,873 50,886 +13 (+0.0%) 🔴
octane-tsrx weather_js_brotli 44,429 44,407 −22 (−0.0%) 🟢
octane-tsrx weather_app_brotli 6,661 6,663 +2 (+0.0%) 🔴
octane-tsrx weather_fw_raw 134,667 134,688 +21 (+0.0%) 🔴
octane-tsrx weather_fw_gzip 43,002 43,015 +13 (+0.0%) 🔴
octane-tsrx weather_fw_brotli 37,768 37,744 −24 (−0.1%) 🟢
octane-tsrx bindings_js_raw 687,418 688,832 +1,414 (+0.2%) 🔴
octane-tsrx bindings_js_gzip 224,584 225,006 +422 (+0.2%) 🔴
octane-tsrx bindings_js_brotli 190,787 191,175 +388 (+0.2%) 🔴
octane-tsrx bindings_app_brotli 96,207 96,214 +7 (+0.0%) 🔴
octane-tsrx bindings_fw_raw 339,780 341,194 +1,414 (+0.4%) 🔴
octane-tsrx bindings_fw_gzip 108,917 109,339 +422 (+0.4%) 🔴
octane-tsrx bindings_fw_brotli 94,580 94,961 +381 (+0.4%) 🔴
octane-tsrx full_fw_raw 567,135 568,620 +1,485 (+0.3%) 🔴
octane-tsrx full_fw_gzip 170,792 171,214 +422 (+0.2%) 🔴
octane-tsrx full_fw_brotli 143,732 143,953 +221 (+0.2%) 🔴
octane-jsx js_raw 187,708 187,729 +21 (+0.0%) 🔴
octane-jsx js_gzip 59,515 59,529 +14 (+0.0%) 🔴
octane-jsx js_brotli 51,743 51,727 −16 (−0.0%) 🟢
octane-jsx app_gzip 2,857 2,856 −1 (−0.0%) 🟢
octane-jsx app_brotli 2,412 2,408 −4 (−0.2%) 🟢
octane-jsx fw_raw 179,443 179,464 +21 (+0.0%) 🔴
octane-jsx fw_gzip 56,658 56,673 +15 (+0.0%) 🔴
octane-jsx fw_brotli 49,331 49,319 −12 (−0.0%) 🟢
octane-jsx full_fw_raw 567,135 568,620 +1,485 (+0.3%) 🔴
octane-jsx full_fw_gzip 170,792 171,214 +422 (+0.2%) 🔴
octane-jsx full_fw_brotli 143,732 143,953 +221 (+0.2%) 🔴

11 other measured values are unchanged.

Public-import reachability bundles (bytes)

❌ 40 value(s) exceed their committed budget. Reduce the growth, or raise the budget in a separate pull request that names the bytes and the reason (CONTRIBUTING.md, "Size budgets").

target metric head budget over
cli-spa-starter raw 102,179 102,165 +14
cli-spa-starter gzip 33,980 33,978 +2
root-static-specialized raw 72,693 72,680 +13
root-chained-jsx raw 74,571 74,558 +13
root-static raw 165,545 165,531 +14
root-static-local raw 72,692 72,679 +13
root-callback-local raw 74,597 74,584 +13
hooks-state raw 84,414 84,401 +13
prop-attributes raw 84,668 84,655 +13
context raw 96,621 96,608 +13
hydrate-root raw 138,068 138,055 +13
deferred-hydration raw 221,365 221,351 +14
hydrate-frame raw 364,520 364,506 +14
suspense-transition raw 141,550 140,150 +1,400
suspense-transition gzip 44,727 44,358 +369
suspense-transition brotli 39,252 39,132 +120
component-owned-effects raw 77,056 77,044 +12
binding-hooks raw 82,913 82,900 +13
binding-base-ui-vite raw 199,748 198,341 +1,407
binding-base-ui-vite gzip 62,770 62,384 +386
binding-base-ui-vite brotli 54,452 54,383 +69
binding-base-ui-esbuild raw 215,268 213,852 +1,416
binding-base-ui-esbuild gzip 69,718 69,318 +400
binding-base-ui-esbuild brotli 60,488 60,247 +241
binding-radix-vite raw 201,779 200,371 +1,408
binding-radix-vite gzip 63,341 62,992 +349
binding-radix-vite brotli 54,997 54,923 +74
binding-radix-esbuild raw 217,092 215,676 +1,416
binding-radix-esbuild gzip 70,264 69,893 +371
binding-radix-esbuild brotli 60,899 60,813 +86
binding-mantine-hooks-vite raw 86,471 86,458 +13
binding-mantine-hooks-esbuild raw 90,840 90,827 +13
binding-apollo-client-vite raw 342,199 340,784 +1,415
binding-apollo-client-vite gzip 105,054 104,707 +347
binding-apollo-client-vite brotli 91,622 91,544 +78
binding-apollo-client-esbuild raw 365,411 363,991 +1,420
binding-apollo-client-esbuild gzip 116,033 115,690 +343
binding-apollo-client-esbuild brotli 101,228 101,084 +144
binding-usehooks-ts-vite raw 87,237 87,224 +13
binding-usehooks-ts-esbuild raw 91,608 91,593 +15
target metric base head Δ
cli-spa-starter raw 102,158 102,179 +21 (+0.0%) 🔴
cli-spa-starter gzip 33,956 33,980 +24 (+0.1%) 🔴
cli-spa-starter brotli 29,868 29,877 +9 (+0.0%) 🔴
root-static-specialized raw 72,672 72,693 +21 (+0.0%) 🔴
root-static-specialized gzip 23,803 23,820 +17 (+0.1%) 🔴
root-static-specialized brotli 21,280 21,295 +15 (+0.1%) 🔴
root-chained-jsx raw 74,550 74,571 +21 (+0.0%) 🔴
root-chained-jsx gzip 24,312 24,322 +10 (+0.0%) 🔴
root-chained-jsx brotli 21,717 21,732 +15 (+0.1%) 🔴
root-static raw 165,524 165,545 +21 (+0.0%) 🔴
root-static gzip 52,253 52,270 +17 (+0.0%) 🔴
root-static brotli 45,536 45,520 −16 (−0.0%) 🟢
root-static-local raw 72,671 72,692 +21 (+0.0%) 🔴
root-static-local gzip 23,785 23,802 +17 (+0.1%) 🔴
root-static-local brotli 21,285 21,290 +5 (+0.0%) 🔴
root-callback-local raw 74,576 74,597 +21 (+0.0%) 🔴
root-callback-local gzip 24,316 24,332 +16 (+0.1%) 🔴
root-callback-local brotli 21,797 21,750 −47 (−0.2%) 🟢
hooks-state raw 84,393 84,414 +21 (+0.0%) 🔴
hooks-state gzip 27,766 27,786 +20 (+0.1%) 🔴
hooks-state brotli 24,720 24,725 +5 (+0.0%) 🔴
prop-attributes raw 84,647 84,668 +21 (+0.0%) 🔴
prop-attributes gzip 27,767 27,782 +15 (+0.1%) 🔴
prop-attributes brotli 24,738 24,753 +15 (+0.1%) 🔴
context raw 96,600 96,621 +21 (+0.0%) 🔴
context gzip 31,465 31,475 +10 (+0.0%) 🔴
context brotli 27,930 27,955 +25 (+0.1%) 🔴
hydrate-root raw 138,047 138,068 +21 (+0.0%) 🔴
hydrate-root brotli 38,674 38,631 −43 (−0.1%) 🟢
deferred-hydration raw 221,344 221,365 +21 (+0.0%) 🔴
deferred-hydration gzip 69,665 69,679 +14 (+0.0%) 🔴
deferred-hydration brotli 60,083 60,118 +35 (+0.1%) 🔴
hydrate-frame raw 364,499 364,520 +21 (+0.0%) 🔴
hydrate-frame gzip 112,934 112,947 +13 (+0.0%) 🔴
hydrate-frame brotli 96,589 96,534 −55 (−0.1%) 🟢
suspense-transition raw 140,148 141,550 +1,402 (+1.0%) 🔴
suspense-transition gzip 44,345 44,727 +382 (+0.9%) 🔴
suspense-transition brotli 38,926 39,252 +326 (+0.8%) 🔴
component-owned-effects raw 77,036 77,056 +20 (+0.0%) 🔴
component-owned-effects gzip 25,142 25,152 +10 (+0.0%) 🔴
component-owned-effects brotli 22,474 22,483 +9 (+0.0%) 🔴
binding-hooks raw 82,892 82,913 +21 (+0.0%) 🔴
binding-hooks gzip 27,406 27,417 +11 (+0.0%) 🔴
binding-hooks brotli 24,477 24,498 +21 (+0.1%) 🔴
binding-base-ui-vite raw 198,340 199,748 +1,408 (+0.7%) 🔴
binding-base-ui-vite gzip 62,351 62,770 +419 (+0.7%) 🔴
binding-base-ui-vite brotli 54,201 54,452 +251 (+0.5%) 🔴
binding-base-ui-esbuild raw 213,852 215,268 +1,416 (+0.7%) 🔴
binding-base-ui-esbuild gzip 69,298 69,718 +420 (+0.6%) 🔴
binding-base-ui-esbuild brotli 60,059 60,488 +429 (+0.7%) 🔴
binding-radix-vite raw 200,370 201,779 +1,409 (+0.7%) 🔴
binding-radix-vite gzip 62,969 63,341 +372 (+0.6%) 🔴
binding-radix-vite brotli 54,674 54,997 +323 (+0.6%) 🔴
binding-radix-esbuild raw 215,676 217,092 +1,416 (+0.7%) 🔴
binding-radix-esbuild gzip 69,871 70,264 +393 (+0.6%) 🔴
binding-radix-esbuild brotli 60,620 60,899 +279 (+0.5%) 🔴
binding-mantine-hooks-vite raw 86,450 86,471 +21 (+0.0%) 🔴
binding-mantine-hooks-vite gzip 28,376 28,391 +15 (+0.1%) 🔴
binding-mantine-hooks-vite brotli 25,232 25,276 +44 (+0.2%) 🔴
binding-mantine-hooks-esbuild raw 90,819 90,840 +21 (+0.0%) 🔴
binding-mantine-hooks-esbuild gzip 30,491 30,509 +18 (+0.1%) 🔴
binding-mantine-hooks-esbuild brotli 27,122 27,136 +14 (+0.1%) 🔴
binding-apollo-client-vite raw 340,784 342,199 +1,415 (+0.4%) 🔴
binding-apollo-client-vite gzip 104,693 105,054 +361 (+0.3%) 🔴
binding-apollo-client-vite brotli 91,337 91,622 +285 (+0.3%) 🔴
binding-apollo-client-esbuild raw 363,991 365,411 +1,420 (+0.4%) 🔴
binding-apollo-client-esbuild gzip 115,667 116,033 +366 (+0.3%) 🔴
binding-apollo-client-esbuild brotli 100,954 101,228 +274 (+0.3%) 🔴
binding-usehooks-ts-vite raw 87,216 87,237 +21 (+0.0%) 🔴
binding-usehooks-ts-vite gzip 28,580 28,594 +14 (+0.0%) 🔴
binding-usehooks-ts-vite brotli 25,511 25,536 +25 (+0.1%) 🔴
binding-usehooks-ts-esbuild raw 91,585 91,608 +23 (+0.0%) 🔴
binding-usehooks-ts-esbuild gzip 30,727 30,750 +23 (+0.1%) 🔴
binding-usehooks-ts-esbuild brotli 27,414 27,420 +6 (+0.0%) 🔴

37 other measured values are unchanged.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
octane-website 6141db3 Commit Preview URL

Branch Preview URL
Oct 08 2026, 01:15 PM

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
octane-website-mcp 6141db3 Commit Preview URL

Branch Preview URL
Oct 08 2026, 01:18 PM

trueadm and others added 2 commits October 8, 2026 13:38
FLUSHED_TRANSITION_UPDATES is retained while any block waits for the
transition task, so a block's already-rendered updates can still be listed
when a later pending cue splits on that block. Hook cells were guarded by
their consumed renderTransition, but plain cells (useDeferredValue's swap,
useLinkedState) were reverted to their pre-transition base: the cue flashed
the deferred value from before the swap.

When a block that is not queued is scheduled at transition priority, a render
has consumed every update retained for it, so queueTransitionBlock marks them
rendered and the cue's committed-cell exposure skips them. A hold that takes
the entries clears the mark, so hold and promotion behave as before.

Reported by Cursor Bugbot on #1888.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Reverted with fdb2de9 before merge; the raise lands through #1887.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
trueadm added a commit that referenced this pull request Oct 8, 2026
#1888 now also marks retained transition updates its block already rendered,
so a later split cue cannot expose a committed plain cell's base: about
+128 raw and +45 gzip on the nine transition scenarios. Values from
--write-budgets on #1888's head.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
trueadm and others added 3 commits October 8, 2026 13:48
# Conflicts:
#	benchmarks/bundle-size/minimal-budgets.json
#	docs/differences-from-react.md
#	packages/octane/src/runtime.ts
…sition's capture

#1872 pinned the old same-root order, where the Action cue and the explicit
transition state in one component rendered together in the microtask flush and
shared its native capture. The cue now renders apart from that state, as in the
separate-root case: it commits without a capture, and the state is captured when
its task renders it.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The bundle-size gates now run in their own job (#1889), so the runtime shards
no longer need the raised budgets to run. The raise lands through #1887.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@trueadm
trueadm merged commit 90a57d8 into main Oct 8, 2026
30 of 33 checks passed
@trueadm
trueadm deleted the fix/transition-cue-split branch October 8, 2026 13:59
trueadm added a commit that referenced this pull request Oct 8, 2026
The merge took main's budget files. Each raw and gzip row that main
(abe9b42) fits drops by exactly what this change saves against main,
measured per scenario on both trees. Brotli rows keep main's values unless the
ratchet asks for less. That gives 24 lowers and no raises.

Main measures over 35 rows after #1875 and #1888, and #1887 budgets that
growth. Those rows keep main's values here. Merging #1887 will re-lower the
ones this change also saves on.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
trueadm added a commit that referenced this pull request Oct 8, 2026
…udgets

#1888 (the split transition cue) merged ahead of its budget-only raise #1887,
so main's transition-using rows exceed their ceilings. #1893 has since raised
budgets for #1892, which is still open, but measured without #1888's growth.

Raise only the 30 rows still over their ceilings on main 1e74902, to
measured + 32 raw/gzip (+ 256 brotli) from run-minimal.mjs and run.mjs
--write-budgets, and keep every other value, including #1893's pending raises:
- suspense-transition, Base UI, Radix and Apollo bindings, bindings app:
  about +1.12 to +1.15 kB raw, +0.30 to +0.37 kB gzip
- hydrate-frame +63 raw / +37 gzip; root-static brotli +279

The 62 rows #1893 raised stay above their ratchet floor until #1892 lands.
This supersedes #1887.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
trueadm added a commit that referenced this pull request Oct 8, 2026
… a row (#1890)

* perf(octane): copy a keyed reorder's record directly until it relinks a row

A keyed reorder records its list at the first row index it rewrites, before it
knows whether it will relink a few rows or every row. Since #1833 that record
allocated its `links` Map and a per-journal records Map up front. When the
reorder then reached the LIS path, `fullForSlotRecord` walked the chain through
the empty links Map and, for a key Map already out of chain order, built a Set
of every row to filter it.

The record now gets its links Map at its first relink (`forSlotLinks`). Until
then only index writes have run, which change neither the chain nor the key
Map, so converting it copies the list as it stands, which is the full form's
cost before #1833. The record rides in the spare slot of its own undo entry,
found again through the window's `seen` index, so `SLOT_RECORDS` is gone and the
record still lives exactly as long as its log.

- recursive-context zero-context reorder: 4 Map constructions -> 2, so
  context-cache-work.mjs passes its ceiling again (bisected to e595a13).
- js-framework reorder matrix (octane-tsrx, paired, 12 samples): rotatef,
  rotateb and displace3-8 are 22-27% faster than main and within 5% of the
  runtime before #1833; removals and inserts keep #1833's gains.
- Framework bundles are 129-137 raw bytes smaller; budgets lowered.

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

* perf(octane): look a keyed list's record up only when its window has an entry

The PR bench counted two more production calls on every js-framework
operation: journalForSlot and journalForOwnedListClear called the record
lookup, and fullForSlotRecord with no record, even for a list's first record in
a render, where there is no entry to find. Skip both when the list has no
entry. Every js-framework calls_* and dom_* counter now equals main's
(pair.mjs --work-only).

Lower the bindings app and total brotli budgets the ratchet now asks for.

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

* perf(octane): read a keyed list's record from its undo entry inline

Inline the record lookup in journalForSlot and journalForOwnedListClear. With
the helper, the bindings app's framework chunk compressed 21 gzip bytes larger
than main's, past its budget, although raw was 104 bytes smaller. Inline, it is
5 gzip bytes larger and 10 under the budget. Production calls are unchanged:
every js-framework calls_* and dom_* counter equals main's (pair.mjs
--work-only against c0192ec).

Re-measure the bundle budgets on current main. The merges took main's budget
files, and this writes 40 lowers and no raises.

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

* ci(bench): lower the budgets by this change's measured saving over #1891

The merge took main's budget files. #1891 raised 70 rows ahead of #1875,
which is still open. Each raw and gzip row now drops by exactly what this change
saves against main (2f81266), measured per scenario on both trees. A row
#1891 raised therefore keeps #1875's headroom. Brotli rows keep main's values,
and no value is raised.

Every head measurement fits its budget. The ratchet flags only the 70 rows
#1891 raised for #1875, as it does for any PR until #1875 lands.

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

* ci(bench): re-lower the budgets this change saves on after #1875 landed

The merge took main's budget files. Each raw and gzip row that main
(abe9b42) fits drops by exactly what this change saves against main,
measured per scenario on both trees. Brotli rows keep main's values unless the
ratchet asks for less. That gives 24 lowers and no raises.

Main measures over 35 rows after #1875 and #1888, and #1887 budgets that
growth. Those rows keep main's values here. Merging #1887 will re-lower the
ones this change also saves on.

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

* ci(bench): re-lower the budgets this change saves on over #1893

The merge took main's budget files (6eef1e0). Each raw and gzip row that
main fits drops by exactly what this change saves against main, measured per
scenario on both trees. Brotli rows keep main's values unless the ratchet asks
for less. That gives 37 lowers and no raises. The rows #1893 raised for #1892
keep #1892's growth. The 30 rows main exceeds until #1887 lands keep main's
values.

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

* ci(bench): re-lower the budgets this change saves on over 87d9f95

The merge took main's budget files. Main now fits every row. Each raw and gzip
row drops by exactly what this change saves against main, measured per scenario
on both trees. Brotli rows keep main's values unless the ratchet asks for less.
That gives 63 lowers and no raises. The rows #1893 raised for #1892 keep
#1892's growth.

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

* ci(bench): lower the budgets by this change's saving over main's ratchet

The merge took main's budget files. e14fbdf set every budget to main's
measured bytes plus headroom. Each raw and gzip row drops by exactly what this
change saves against main, measured per scenario on both trees. Brotli rows
keep main's values unless the ratchet asks for less. That gives 56 lowers and
no raises. Every ceiling and the ratchet hold locally, and so do the
budget-raise and hydration-free checks.

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

* ci(bench): lower the budgets by this change's saving after #1892

The merge took main's budget files (68aa481), which match main's measured
bytes. Each raw and gzip row drops by exactly what this change saves against
main, measured per scenario on both trees. Brotli rows keep main's values
unless the ratchet asks for less. That gives 54 lowers and no raises.

Locally, binding-mantine-hooks-esbuild brotli is 7 bytes over main's value,
27,265 against 27,258. Its raw and gzip bytes equal main's: esbuild assigns
different minified names in that bundle, and brotli compresses them
differently.

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

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
Co-authored-by: domgan-oai <[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 fix PR: bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant