-
-
Notifications
You must be signed in to change notification settings - Fork 23
Open
Description
Which project does this relate to?
Start
Describe the bug
Crash on build when attempting to build for cloudflare-module
as target.
$ vite build
vite v6.3.5 building for production...
Generated route tree in 92ms
β 200 modules transformed.
.tanstack/start/build/client-dist/.vite/manifest.json 2.11 kB β gzip: 0.50 kB
.tanstack/start/build/client-dist/assets/logo-CHtJT8UQ.svg 8.61 kB β gzip: 3.65 kB
.tanstack/start/build/client-dist/assets/styles-CL-3Q1mh.css 14.74 kB β gzip: 3.56 kB
.tanstack/start/build/client-dist/assets/index-DbO1V9eu.js 0.83 kB β gzip: 0.47 kB
.tanstack/start/build/client-dist/assets/demo.start.api-request-PH23D0AI.js 0.89 kB β gzip: 0.53 kB
.tanstack/start/build/client-dist/assets/demo.start.server-funcs-DB-hyUWC.js 1.73 kB β gzip: 0.93 kB
.tanstack/start/build/client-dist/assets/devtools-DvivmTDS.js 47.52 kB β gzip: 13.44 kB
.tanstack/start/build/client-dist/assets/main-jjdci18j.js 306.54 kB β gzip: 98.66 kB
β built in 1.19s
vite v6.3.5 building SSR bundle for production...
"createRequestHandler", "defineHandlerCallback", "transformPipeableStreamWithRouter" and "transformReadableStreamWithRouter" are imported from external module "@tanstack/router-core/ssr/server" but never used in "node_modules/@tanstack/start-server-core/dist/esm/createStartHandler.js" and "node_modules/@tanstack/start-server-core/dist/esm/index.js".
"H3Error", "MIMES", "callNodeListener", "createApp", "createAppEventHandler", "createError", "createEvent", "createRouter", "defineLazyEventHandler", "defineNodeListener", "defineNodeMiddleware", "defineRequestMiddleware", "defineResponseMiddleware", "defineWebSocket", "dynamicEventHandler", "fromNodeMiddleware", "fromPlainHandler", "fromWebHandler", "isCorsOriginAllowed", "isError", "isEventHandler", "isStream", "isWebResponse", "lazyEventHandler", "promisifyNodeListener", "sanitizeStatusCode", "sanitizeStatusMessage", "serveStatic", "splitCookiesString", "toEventHandler", "toNodeListener", "toPlainHandler", "toWebHandler" and "useBase" are imported from external module "h3" but never used in "node_modules/@tanstack/start-server-core/dist/esm/h3.js" and "node_modules/@tanstack/start-server-core/dist/esm/index.js".
β 55 modules transformed.
[plugin vite:css-post] Sourcemap is likely to be incorrect: a plugin (vite:css-post) was used to transform files, but didn't generate a sourcemap for the transformation. Consult the plugin documentation for help
β built in 209ms
β Generated public .output/public nitro 3:29:25 PM
βΉ Building Nitro Server (preset: cloudflare-module, compatibility date: 2024-11-19) nitro 3:29:25 PM
ERROR RollupError: node_modules/@tanstack/devtools/dist/esm/components/content-panel.js (1:19): "use" is not exported by "node_modules/solid-js/web/dist/server.js", imported by "node_modules/@tanstack/devtools/dist/esm/components/content-panel.js". nitro 3:29:26 PM
1: import { template, use, insert, memo, addEventListener, effect, className, delegateEvents } from "solid-js/web";
^
2: import { useDevtoolsSettings } from "../context/use-devtools-context.js";
3: import { useStyles } from "../styles/use-styles.js";
error during build:
RollupError: node_modules/@tanstack/devtools/dist/esm/components/content-panel.js (1:19): "use" is not exported by "node_modules/solid-js/web/dist/server.js", imported by "node_modules/@tanstack/devtools/dist/esm/components/content-panel.js".
at getRollupError (file:///home/oof2win2/git/cloudflare-bug-repro/node_modules/rollup/dist/es/shared/parseAst.js:401:41)
at error (file:///home/oof2win2/git/cloudflare-bug-repro/node_modules/rollup/dist/es/shared/parseAst.js:397:42)
at Module.error (file:///home/oof2win2/git/cloudflare-bug-repro/node_modules/rollup/dist/es/shared/node-entry.js:16915:16)
at Module.traceVariable (file:///home/oof2win2/git/cloudflare-bug-repro/node_modules/rollup/dist/es/shared/node-entry.js:17367:29)
at ModuleScope.findVariable (file:///home/oof2win2/git/cloudflare-bug-repro/node_modules/rollup/dist/es/shared/node-entry.js:15037:39)
at ReturnValueScope.findVariable (file:///home/oof2win2/git/cloudflare-bug-repro/node_modules/rollup/dist/es/shared/node-entry.js:5626:38)
at FunctionBodyScope.findVariable (file:///home/oof2win2/git/cloudflare-bug-repro/node_modules/rollup/dist/es/shared/node-entry.js:5626:38)
at ReturnValueScope.findVariable (file:///home/oof2win2/git/cloudflare-bug-repro/node_modules/rollup/dist/es/shared/node-entry.js:5626:38)
at FunctionBodyScope.findVariable (file:///home/oof2win2/git/cloudflare-bug-repro/node_modules/rollup/dist/es/shared/node-entry.js:5626:38)
at Identifier.bind (file:///home/oof2win2/git/cloudflare-bug-repro/node_modules/rollup/dist/es/shared/node-entry.js:5400:40)
error: script "build" exited with code 1
Your Example Website or App
https://github.com/oof2win2/tanstack-cloudflare-bug-repro
Steps to Reproduce the Bug or Issue
- Install a fresh version via
pnpx create-start-app@latest
- Follow the instructions at https://tanstack.com/start/latest/docs/framework/react/hosting#cloudflare-workers
- Build the project, observe crash
Expected behavior
The project should build successfully
Screenshots or Videos
No response
Platform
- Router / Start Version: 1.131.7
- OS: debian13
- Bundler: vite
- Bundler Version: 6.3.5
Additional context
No response
badams, josiahNgu, matt45400 and noahsmiths
Metadata
Metadata
Assignees
Labels
No labels