Skip to content

Track 2026-09-03..10 main regression sweep: $-suffix native-read inference, Strong @switch scoping, aria/shadcn port defects, unchangeset core changes, dead Bench CI #1037

Closed

Description

@trueadm

Summary

Track the follow-up to a regression sweep of every commit merged to main between 2026-09-03 and 2026-09-10 (83 commits, PRs #943 through #1033, main @ 856febc73). This is one coordination issue; fixes should land as separate package-owned PRs with regressions in the owning package per CLAUDE.md.

Method: per-area diff review of every non-generated source hunk (runtime render/commit, events/transitions/hooks, SSR, universal core, compiler, Strong mode, bindings, tooling), each suspicious spot re-verified against current main; the packages/octane Vitest suite locally (18,656 pass, one load flake); log triage of every red CI run on main this week; and scratchpad reproductions of the top items (marked confirmed). No repo files were modified.

Headline: main is green and nothing is a blocker. The 13 render/commit/reconciler perf commits, the 18 event/transition/hook/context commits, the universal-core commits, and the app-core route indexing (#951/#955, 160k-query old-vs-new differential fuzz) came up clean. The items below are the concrete defects, the core changes that shipped under binding-PR titles without changesets, and the CI signal problems.

Defects

Items 1–6 are resolved. The core-change reviews and CI signal work below remain open.

1. Any $-suffixed name flips a module into native-signal-read mode (#997) — confirmed

packages/octane/src/compiler/native-read-diagnostics.js:75-101 (nativeReadOptions), wired at compile.js and slot-hooks.js. #997 removed the explicit nativeReads option and replaced it with syntactic inference: an Identifier/JSXIdentifier, member property, or object key whose name ends in $ anywhere in runtime AST enables native reads for the whole module. $ itself qualifies, as do rxjs-style foo$ names.

Repro (compile with renderer: { target }):

import { useEffect, useState } from 'octane';
export function Ticker() @{
  const [n, setN] = useState(0);
  useEffect(() => { const tick$ = setInterval(() => setN((v) => v + 1), 1000); return () => clearInterval(tick$); }, []);
  <div>{n as string}</div>
}
name target result
tick dom hoisted _$template path
tick$ dom beginNativeReadScope + nativeCreateScopedElement path (no hoisted template)
tick$ universal throws Octane native signal reads support only the DOM client and server.

The design comment says the heuristic is deliberate ("do not require a direct signals import"); the consequence is a compile failure for every universal/Lynx module using a $ naming convention and a silent render-path change on the DOM client, with no opt-out left. Suggested guard: require an octane/signals* import (or a $ binding that resolves to one) before inferring, or restore an explicit opt-out.

  • Fix in packages/octane compiler + regression (.tsrx with import $ from 'jquery' / const tick$ compiles on universal and keeps the template path on DOM).

2. Strong mode: @switch arms have no scope in the phase analyzer (#963, #1029, #1031, #1033) — confirmed

packages/octane/src/compiler/strong-mode.js visit() (the switch near line 3073) has no JSXSwitchExpression case, so @case/@default consequents fall to the generic child loop (~line 3650) and are visited in the enclosing scope with no predeclareStatements. The locality walker added in #963 handles the same node correctly (~line 729, createScope(scope, 'function', branch.consequent)) and is the template for the fix.

Consequences, each reproduced against compile() with Strong enabled:

  • let revision = 0; function advance() { revision++ } + @case 'a': { const revision = props.r; <p>{revision as string}</p> } → false OCTANE_STRONG_RENDER_MODULE_STATE_READ (arm-local shadow invisible). The same input in an @if arm compiles clean.
  • const ref = useRef(null) in the parent + @case 'a': { const ref = props.other; <p>{ref.current as string}</p> } → false RENDER_REF_READ; same shape with getN/setN/items gives false RENDER_STATE_GETTER_CALL / RENDER_STATE_UPDATE / RENDER_SNAPSHOT_MUTATION (bindings from one arm leak into later arms).
  • Missed diagnostic: @case 'a': { function read() { return ref.current; } <p>{read() as string}</p> } compiles clean; the identical @if arm throws RENDER_REF_READ (arm-local function declarations are never bound).

Also (lower): PropertyDefinition/AccessorProperty values (strong-mode.js ~3125) are visited as render-time regardless of node.static, so class Entry { value = revision } instantiated only from a handler is rejected. Object-literal getters/methods are never visited (missed diagnostics). Strong mode is opt-in, which bounds the impact.

  • Add a JSXSwitchExpression case to visit() mirroring the locality walker; visit non-static class fields as deferred; add the arm-shadow, arm-leak, and arm-local-function regressions.

3. React Aria port defects (#978)

  • VirtualizerItem drops shouldObserveItemSize — confirmed. packages/aria/src/virtualizer/VirtualizerItem.tsx:31-39 destructures the prop but the useVirtualizerItem({ layoutInfo, virtualizer, ref }) call omits it, so the new ResizeObserver path in useVirtualizerItem.tsx:61-85 is unreachable through the component. <Virtualizer shouldObserveItemSize> items whose content grows are never re-measured.
  • Dead propagation guard in useGridListItem — confirmed dead. packages/aria/src/gridlist/useGridListItem.tsx:446-452 guards baseOnKeyDown on 'isPropagationStopped' in e, which is never true for the native KeyboardEvent Octane delivers, so the row's press handler always runs. With keyboardNavigationBehavior="tab" and a native checkbox/link/button inside a row, Space/Enter still presses/selects the row, which is exactly what upstream's comment at line 441 guards. Under Octane the equivalent is e.cancelBubble. The same pattern was added to interactions/createEventHandler.ts:86-95 where it is harmless (net behavior unchanged).
  • useKeyboard hands the raw native event to user handlers when shortcuts is set — packages/aria/src/interactions/useKeyboard.ts:84-85 uses chain(props.onKeyDown, shortcutOnKeyDown) while the prop type promises BaseEvent<KeyboardEvent>; useMenuItem.ts:390-393 routes consumer onKeyDown this way, so a MenuItem onKeyDown={e => e.continuePropagation()} throws TypeError. Upstream has the same chain, but under Octane isDefaultPrevented()/isPropagationStopped() are also missing.
  • Type-only losses: packages/aria/src/tokenfield/useTokenField.tsx:45-46 dropped FocusableProps from AriaTokenFieldProps (import left unused), so autoFocus/onFocus/onBlur/onFocusChange fail tsrx-tsc on TokenField though the runtime honors them; packages/aria/src/components/Tree.ts:1388-1389 changed the exported TreeSection signature to GridListHeaderProps & { ref?: any }, so <TreeSection items={…}> is an excess-property error.
  • Lower: packages/aria/src/index.ts:379 exports getSelection, which upstream's useTokenField exports do not; useDialog.ts:64 calls useSlotId() without a manual slot inside a manual-slot .ts hook (falls back to the global key; latent collision); converted .tsx hooks accept and ignore _slot (latent collision only from non-compiled .ts callers that invoke the same hook twice; none found).

4. shadcn port (#978)

Resolved in #1042.

  • Remove the unused cn-menu-target cn-menu-translucent classes from Base UI Select and its React reference, matching the pinned shadcn 4.21.0 default menuColor transform.
  • Open Select and NavigationMenu popups in the differential and compare their portaled content with React, including Select options and scroll controls.
  • Move unused clsx and tailwind-merge runtime dependencies to development dependencies in @octanejs/shadcn.

5. SSR spliceHead and fragment-root <head> (#1001) — resolved

At the sweep baseline, packages/octane/src/runtime.server.ts:6573-6583 spliced hoisted head markup before </head> only when isDocumentRoot(body) (first-bytes <html check); everything else is prepended. A root fragment that authors its own <head> without <html> (the Fizz-supported preamble shape, used when a server template owns <html>):

export function Page() @{ <><head><meta charSet="utf-8" /></head><body><title>T</title><main>x</main></body></> }
  • before perf: skip head-close scan for SSR fragments #1001: <!--[--><head>…<meta charSet="utf-8"><title>T</title></head><!--]-->…
  • at sweep baseline: <!--rnh-…--><meta charSet="utf-8"><!--/rnh-…--><!--rnh-…--><title>T</title><!--/rnh-…--><!--[--><head><!--[--><!--]--></head><!--]-->…

At the sweep baseline, the compiler hoisted the authored <meta> out of <head>, so the authored head serialized empty and metadata landed before it. The SSR preamble behavior and hydration boundary are now documented and covered by regressions.

  • Fold hoisted metadata and streamed scoped styles into a leading authored <head> in fragment SSR output (#1045). A fragment preamble composed into host-owned <html> remains SSR-only; hydrate a body root with headChannel: 'separate' instead.

6. Tooling and packages

Core changes that rode binding PRs without a describing changeset

These are not known to be wrong; they are runtime/compiler semantics changes that were not reviewed as such because they landed inside large binding PRs. Each deserves a deliberate look and, where user-visible, a changeset.

  • feat(base-ui): complete the Base UI 1.8.0 binding #973 (184631809, "complete the Base UI 1.8.0 binding") changed ~600 lines of packages/octane/src/runtime.ts:
    • plain flush() (flushWork) now drains layout-effect cascades synchronously via the new drainLayoutUpdates, bounded only by LAYOUT_CASCADE_LIMIT = 50 and the nested-update guard; flushSync's convergence brake ("a block re-scheduling itself is non-convergent, defer to the async scheduler") was removed and its comment rewritten. Bounded (the update-reconciliation conformance tests still pass), but it is a scheduling-semantics change.
    • ref-callback state writes are now collected during drainCommitRefs and scheduled once after both detach and attach phases, skipped when the value round-trips (Object.is(state.value, previous)).
    • act() was rewritten: isInActScope, actCallbackDepth/asyncActCallbackDepth, a MessageChannel task checkpoint replacing the 5-microtask loop, and flush() now catches render errors inside an act scope and defers them to the act result.
    • journalRootRange undo now bails when a newer undo already removed the range's anchors.
    • packages/zustand/tests/conformance/unstable-selectors.test.ts was rewritten to pin Maximum update depth exceeded at mount for unstable useSyncExternalStore selectors (React parity, but user-visible).
    • The only octane changesets in that PR describe the peer floor / isInActScope export and the streamed @catch adoption fix.
  • feat: update shadcn and React Aria bindings #978 changed packages/octane/src/compiler/compile.js:20737-20742 so Float <style href precedence> CSS ships sheet.source verbatim instead of the scoped serializer output (which pruned unused selectors and renamed keyframes). Correct fix with a regression in tests/float-resources.test.ts, but user-visible compiler output changed under a bindings title. Related: packages/base-ui/src/utils/styles.tsrx wraps the style in a template component because a value-position <style href precedence children={css}/> still renders inline rather than hoisting; docs/differences-from-react.md promises React semantics there.
  • feat(base-ui): complete the Base UI 1.8.0 binding #973 added retry: process.env.CI ? 1 : 0 to packages/base-ui/tests/vitest.config.ts:18 and packages/base-ui-utils/tests/vitest.config.ts:15, which masks Octane-side flakes in CI. packages/testing-library/tests/octane-peer-minimum.test.ts fetches registry.npmjs.org inside the ordinary pnpm test project with no offline skip.
  • fix: update TSRX dependencies and remove upstreamed core patch #979 deleted four volar regression cases plus fixture when dropping the upstreamed @tsrx/core patch; all four assertions still pass against @tsrx/[email protected] (fix present), so only coverage was lost. Consider restoring them as plain regressions.
  • 74650f37d changed packages/base-ui/tests/differential/parity.test.ts:367 from d.step to d.observe, dropping the immediate post-click React/Octane HTML comparison (only the post-entrance-paint state is still compared).

CI signal

  • Recurring parity red on main: packages/base-ui/tests/upstream/src/dialog/popup/DialogPopup.test.tsx finalFocus … fails intermittently (2 of 9 pushes this week) with "An update to DialogRoot was not wrapped in act(...)" from useAnimationFrame → useTransitionStatus. Root cause is the test's bare await waitSingleFrame() between user.click and user.keyboard('{Escape}') running outside asyncWrapper while the act environment is armed; unmount does cancel frames, so this is a harness race, not a binding defect. Upstream fixed it in [dialog] Wrap the finalFocus frame wait in act mui/base-ui#5640 (merged 2026-09-09); packages/base-ui/audit/upstream.lock.json pins v1.8.0 and fix: update TSRX dependencies and remove upstreamed core patch #979 dropped the local patch "for upstream follow-up", so main stays intermittently red until the lock is bumped or the patch is reinstated.
  • Other reds this week, all timing: packages/octane/tests/compiler/volar.test.ts "type-checks absent and optional host spread refs" at 5.4s against the 5s default (1.2s locally; consider a per-test timeout since it runs a real type-check); packages/input-otp/tests/browser/upstream/base.selections.spec.ts selection race (expected '5' to be '4'); jsdom "wrong timeout" in packages/transition-group/upstream/test/Transition-test.js; "Failed to run the test" in the browser lane (SelectPortal, AvatarRoot, PopoverPortal, DrawerContent), each preceded by a Node TimeoutNaNWarning whose source was not located. Locally, packages/octane/tests/hydration/deferred-hydration.test.ts "adopts a split child whose component graph shares eager module state" (octane-prod) fails under concurrent load and passes in isolation.
  • The weekly Bench workflow has failed for ten consecutive runs (since at least 2026-07-06). Since test(bench): add synthetic workerd app workloads #900 it dies at BENCH_ROUNDS=1 node benchmarks/ssr-workerd/app-workloads/run.mjs 1 with ERR_MODULE_NOT_FOUND: Cannot find package 'octane': run.mjs imports octane/compiler/vite but benchmarks/ssr-workerd/package.json declares only miniflare/vite/react (fails locally too). That step precedes node benchmarks/bench.mjs --quick --ratios, so the ratio guards never ran and none of this week's ~40 perf commits was measured by CI. Add the workspace dependency (or createRequire from the repo root), then expect the older ripple/bundle-budget failures to resurface behind it.

Reviewed and clean

Runtime render/commit/reconciler: #982, #986, #976 (one low, pre-existing: retired inert rows restored to pending = true by a root rollback can be dropped by scheduleRender dedupe; reachability not constructed), #989, #990, #1006, #1013, #1014, #1015, #1030, #1025, #1023, #998. Events/transitions/hooks/context/warm plans/styles: #947, #949, #946, #994, #991, #995, #992, #1016, #1017 (PR #929 trusted-event fallback and PR #927 discrete flush confirmed intact), #1019, #1020, #1024, #1028, #996, #957, #960, #961, #956. SSR: #1032, #948, #1000, #999, #964, #974, #945, #968, #969, #1004. Universal core: #1026, #1011, #1010, #1009, #1008, #1005. Compiler: #1018, #1003, #972, #970, #939, #993 (AST immutability suite passes). Bindings/tooling: #971, #952, #953, #950 (no stale react-is references), #1021, #937, #983, 8b100edb2, e8be59141. Strong-mode legitimate patterns (~75 probes: refs/getters in effects and handlers, custom hooks, @for handlers, frozen consts, enums, shadows) all compile clean apart from item 2.

One agent claim that .ts modules skip the hook-in-plain-loop guard for hook methods did not reproduce (for…of over store.useValue throws in both .ts and .tsrx at HEAD) and is excluded.

Activity

  1. added
    bug
    ci
    agent-authored
    on Sep 10, 2026
  2. leonidaz commented on Sep 10, 2026

    @leonidaz
    Collaborator

    for #979, the regression tests were moved to tsrx-org/tsrx since that's where they belong with the fixes.

  3. added a commit that references this issue on Sep 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent-authoredbugci

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions