In dev, an HTTP call by id may run any server function: dev compiles
lazily, so it cannot know what the client references, and a page left
open across a restart must keep working (J4.4). The refusal of server
fns no client code references applies to production builds only.
SPEC J4.2 and G13 say so; the Vite dev RSC pin that asserted the
refusal (and its now unused page helper) is removed, and KNOWN-BUGS
lists the production pin only.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
An edit of an Rsbuild watch build or dev server was taken as applied at the
first end of the compiles that read it. Rspack can still owe a compile then:
a file written after a compile began is reported only by the next watcher,
and an environment that depends on another one runs again after the end is
reported. The edit now also waits, once the watchers are attached, until no
compile started and none is pending.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A route module that reads a member of a JSX element, `(<Tag />).props`,
is printed as `<Tag />.props`, which does not parse, so the route module
fails to load. Same upstream printer bug as the other S3 pins.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Tests that left it open whether the server keeps neutral modules only
client-only code reads now require the drop, checked by outcome:
- `<ClientOnly>` children: the libraries only the children import throw
when they load, so the server render fails if it loads them.
- An aliased re-export of createClientOnlyFn: the SSR environment does not
load the neutral `./browser` module.
- The dead-code shape table runs the server-side removals over a neutral
module instead of a `*.client.*` file.
- The `<ClientOnly>` build adds a neutral module with a top-level effect:
it is absent from the server bundle.
All pass on main. Comments cite J4.11 instead of the removed §5.12.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
J4.11 now requires the server to drop what only client-only code reads
(`<ClientOnly>` children, `createClientOnlyFn` bodies, isomorphic
`.client()` implementations) for every imported module, not only
`*.client.*` and client-only-marked files: a neutral module or a package
left behind reaches the server just like a client-only file would. The
§5.12 freedom is removed, and G3, G16 and C15 follow.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
One list of shapes (@tanstack/compiler-test-utils/dead-code-shapes): a
chain, a diamond, mutual recursion, a class and a const that read each
other, a helper kept code reads too (through typeof, a shorthand, JSX and
export { a as b }), code already dead before the transform, a let a
function assigns, an object and an array holding the helper, a closure a
factory call returns, a default parameter, a namespace import and a
top-level await. Each shape runs through every removal: server fn
handlers, createServerOnlyFn and isomorphic .server() on the client,
createClientOnlyFn and isomorphic .client() on the server, <Hydrate>
children in the parent, split route options and deleteNodes options in
the route module. Each cell checks that the module loads and gives the
right values in both environments, that the module only the removed code
needed is not loaded, and that kept and already-dead code stay.
Main fails ten cells. New root cause S7: the const of a class and const
cycle is removed and the class kept, so the module throws when it loads
(every Start removal, split option, deleteNodes). New J5 entry: the
parent of a <Hydrate> keeps the shared end of a diamond and both halves
of a cycle, with their import.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A browser-only package (it reads window when it loads) that only a
createClientOnlyFn body and an isomorphic .client() read, through a
diamond and a cycle of helpers, never loads on the server: in dev (the
SSR environment) and in Vite and Rsbuild builds, where the server build
must neither bundle it nor warn about its importer, and SSR runs. A new
S2 pin covers the server twin of the class rows: a class only a
client-only fn uses keeps its client-only import on the server today.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The unresolvable-imports build now also fails when the Vite client build
swaps in a browser stub and warns about the importing module (checked by
file and severity), which it did not notice before. It adds a
createServerOnlyFn body and an isomorphic .server() reading node:buffer
through a helper. The server-only routes app gives a page route a server
handler over node:buffer, which deleteNodes removes on the client. The
side-effect hints app adds an unannotated initializer only the handler
reads, which must not reach the client.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Whatever a transform removes takes with it, in that module and before the
bundler, everything only the removed code used, through any shape; it keeps
what kept code reads and what was already dead. Per module only: J4.12 now
says a neutral module's export is the user's, and server-only helpers
belong in *.server.* files. A leftover import of a module the environment
cannot or must not load is not G8 dead code: no stub, no warning, no
polyfill. Cross-references in G8, J4.12 and §5.9.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The route CSS rows (SPEC J2.22) now live in route-css-cases.ts and run
for each bundler from its own file: known-bugs-route-css.test.ts on Vite
dev and build, known-bugs-route-css-rsbuild.test.ts on the Rsbuild dev
server and an Rsbuild production build served as `rsbuild preview` does
(new StartBuild.preview() of the build harness).
New rows: two routes whose components import their own CSS and share a
module. On a route, the other route's styles must not apply, after a
client-side navigation and in the page the server renders there. Vite
passes; on Rsbuild, with the shared module in a chunk of its own, the
page links the other route's stylesheet (Start's Rsbuild manifest, #8780),
pinned as a separate known bug.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Drop the strict-runner adapter (makeRunnerStrict) and its contract test.
With it switched off, every test of the oracle (router-generator,
router-plugin, start-plugin-core, react-start-rsc test:unit and
test:integration) kept its state, pins included.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The README gives one command for the whole oracle and its time, says the
budgets only report unless COMPILER_TEST_BUDGETS=strict, describes the
COMPILER_TESTS_PINS=run switch and the three tables of today's behaviour it
covers, and no longer counts the harness's own tests as part of the
oracle.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The footer Start adds to the route tree declares Register on the app's
framework package. A framework column adds a Solid row (with src/start.ts)
to the type check, next to the two React rows.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A client-rendered Solid app's __root.tsx edit hot-updates in place on
Vite, with and without automatic code splitting. On Rsbuild the page keeps
the old root component, like an unsplit Solid route there: pinned next to
that pin and listed under its cause in KNOWN-BUGS.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The index route component of a Solid Start app holds a <Hydrate> itself,
so the route's split chunk is split again for the children. On the Vite
and Rsbuild dev servers the page hydrates, a click loads the boundary's
code, and the child counts, with no errors.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A directive such as `<span use:tip>` names `tip` only in a JSX attribute;
Solid's JSX transform turns it into a call of `tip` wherever the JSX ends
up. A split Solid route component keeps working (router-plugin, passes).
Split Hydrate children throw "tip is not defined" for a directive declared
in the module or in the component: pinned on Vite and Rsbuild and listed
in KNOWN-BUGS.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With `let input` in the component and `<input ref={input} />` inside a
<Hydrate>, the component's `let` must get the element, as it does with
split={false}. Today the chunk gets `input` as a prop and assigns its own
copy, so the component's `input` stays undefined. Pinned on Vite and
Rsbuild, listed in KNOWN-BUGS.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A boundary inside a component whose children read that component's
reactive props (props.count) must keep reading them live after its code
is split. Runs on Vite and Rsbuild, with split={false} as the reference.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The server fn and isomorphic fn rows of start-build-env-separation now run
for a Solid app too, on Vite and Rsbuild builds. Until now Solid's J4 was
only checked on the Vite dev server.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Seven checks asserted that the client output does not contain a piece of
handler code such as `db.inner()`, which depends on how the compiler
prints. The handlers now hold a `MARK_` string as a fallback they never
return, and the checks look for that string.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A setup file shared by the compiler test projects clears each pin's
`.fails` before it runs, and the shared reporter lists the pins that
passed. The two tables in router-plugin that leave out or loosen cells by
today's behaviour require every cell when the switch is on. Without the
switch nothing changes.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The comment said every boundary's id is compared. The test compares the
ids of the outermost boundaries only.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Rsbuild RSC CSS rows ran for dev and for the production build in one
file, which took about 14 s against the 15 s per-file limit. The rows now
live in rsc-css-rsbuild-app.ts. rsc-css-rsbuild.test.ts runs them on the
dev server, and the new rsc-css-rsbuild-build.test.ts runs them in the
production build, so the two run in parallel. The rows are unchanged.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A denied JSON package imported with `with { type: 'json' }` is a new
mock-shapes case: in Vite dev and in mock-mode Vite and Rsbuild builds,
the importer gets a safe mock and none of the package's data. This
passes on all three.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Vite RSC production build gets the helper-module row: a server fn calls
a module that renders a server component with its own CSS module, and the
page shows it styled. This passes.
The Rsbuild RSC CSS rows now also run in a production build, served by
`rsbuild preview` (a new small helper next to the Vite one). The rows in a
server fn module pass. The helper-module row fails as in dev and stays
pinned under the same cause.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Lowercase component names, a root route with shellComponent, a root route
with context and an undefined component had lost their production check.
They now build for production on Vite and Rspack with the plugin's default
addHmr, and each bundle must equal the build with route HMR off, chunk for
chunk. All pass. The route shapes move to production-bundle.ts, so the
dev rows with addHmr off and the production rows share them.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
In mock-mode builds (Vite and Rsbuild, client and SSR) a violation was
checked only through onViolation. Each mocked row now also needs a printed
warning at the importer's line of the import or of its use, or at a marked
module's marker. The Rsbuild dev row of a server import of a .client file
checks the same. All pass. Only the warning, its file and its line are
checked.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
An exported route option that stays unsplit must be reported once, naming
the route file. The four "keep working" rows of exported options now check
this whenever the option is not lazy. A new row checks it with route HMR
on: an exported component that another route imports, after its split
modules are served, the route module is transformed again and the route
is served again. Both pass. Only the warning, its file and its count are
checked.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With RSC on, the provider compiles server fn modules alongside the RSC CSS
transform. A server fn module that names only createServerFn calls
env-only fns re-exported under other names in a project module. In the
Vite RSC production build, the server-only fn runs and the client-only fn
throws, whether SSR or the browser calls the server fn, and the
server-only body is in no client file. This passes.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A server fn whose handler is a createServerOnlyFn call or a
createIsomorphicFn chain now has a build row on Vite and Rsbuild: it must
work, or the build must fail with an error naming the file. Today the
build succeeds, and the SSR server entry throws while it loads. The two
rows build on their own, so the other call shapes keep sharing one build.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The two dev edits of a module a factory comes from (the end of a re-export
chain, and a renamed env-only factory) now also run under
`rsbuild build --watch`, where the first build has filled the build's
resolution caches. After the rebuild, the importers run the edited code.
Both pass. The edits move to the shared inputs module.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Start compiler resolves factories through build-only paths in a
production build. The dev rows for factories from other project modules,
export * chains, packages that re-export Start, a virtual module factory,
handler forms, builders called as factories and renamed or namespace
createServerFn imports now also run in a Vite and an Rsbuild build. Their
inputs move to a shared module, so both modes read the same rows.
Each build row checks that the client bundle has none of the row's
server-only code, that server fns are callable from the client and run on
the server in place and by id, and that the other exports behave per
environment. Three Rsbuild rows are pinned: an `export *` of the Start
package makes the build fail.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With route HMR on, a plain const page = make() that the loader and the
split component read and that is also the pendingComponent is created
twice: the route module keeps the declaration React HMR renamed, and the
split component gets the shared one. The new expected-fail test expects
make() to run once and the page to render. The passing control next to
it (the same const as component and pendingComponent only) stays.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
SPEC gets J2.22: the CSS a route module imports loads only when that route
matches, whatever it mounts (component, errorComponent, notFoundComponent,
pendingComponent, or no component).
New expected-fail test in start-plugin-core: a React Start app with one
route per case, each importing its own CSS, in a real page on Vite's dev
server and in a production build. At / the route's style must not apply;
after navigating to the route it must. Today the style already applies at
/, in dev and in the build.
The router-plugin test that expected a route's CSS import to load with
the route module no longer checks the CSS; it still checks that an import
whose specifiers all moved is not left behind as a side-effect import.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A server fn whose handler is a createServerOnlyFn call, or a
createIsomorphicFn chain, may either work or be reported: a compile error
naming the file, or in dev a warning naming it. Both pins now accept either
outcome. They still fail: today the module compiles without a report and
the server fn does not run its handler.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
In Vite dev, the maps of the split component's module and of the shared
module name the route file with the code splitter's query
(index.tsx?tsr-split=component, index.tsx?tsr-shared=1), so a debugger sees
another file than the route file. The Vite test now runs one row per throw:
each still maps to its line in the route file, and its module must name
the route file as its source. The loader row passes; the shared and split
rows are expected to fail.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A library that Start discovers through its peer dependency on
@tanstack/react-start is left out of Vite's dev pre-bundling, so a named
import it makes from a CommonJS dependency fails in the browser and the
client route using it does not run. The new expected-fail test opens such
a route in a real page and clicks a button that calls the library.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With route HMR on, a lowercase binding that a split option and an option
kept in the route module both read:
- a destructuring read by the loader, the split component and the unsplit
pendingComponent (the input of #8455) does not compile: pinned;
- a lowercase function component shared by the loader and the split
component fails to load its chunk: pinned, with the arrow form as a
passing control;
- a component created by a call and used as both the component and the
pendingComponent is created once: passes.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
In a production RSC build, a server fn whose only importer is a 'use client'
component rendered by a server component answers 500 when clicked: the
build never registers it. The new expected-fail test clicks the button and
expects the handler's result.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Rulings now cite SPEC clauses; pass, round and variant names and
documents outside the repository are gone. Comments only, plus internal
codes dropped from a few test titles.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
README: what the suite is, how to run and read it, the implementer's
rules. KNOWN-BUGS: one entry per root cause with clause, pins and the
fix's goal, plus the upstream issues that affect the suite. AGENTS:
hard rules, helpers, running, budgets.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Each decision is now a plain statement in the clause it affects. Clause
ids are unchanged; history, dates and justification prose are gone.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
route-hmr-page: routerOptions, plugins, readyTimeout and edit's timeout
(and both HMR pages count requests with hmr-sync's trackRequests instead
of a copy of it); generator-dev-scenarios: the pinVirtualConfigEdits
branch both callers turn off, and the never-passed bounds;
generator-dev-app: bundler, logs() and close(); route-app:
plugins.compilers; build-harness: extraPlugins and buildAndRun's
sideEffects; dev-server: the function form of plugins.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The plugin hosts' settleTimeout/eventTimeout/compileTimeout, build({ mode })
and describe(env, { env, entry }); the Vite dev server's eventTimeout (now
the constant it always was) and its copy of stripAnsi.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Every channel records the console and the process streams: no caller
set anything but those defaults.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>