Error on dev server: [vite] (ssr) Error when evaluating SSR module $vinxi/handler/ssr: Cannot spl...

Has anybody seen this error and can point me in the right direction?

This occurs when running the dev server vinxi dev. It's a 503 error, for all pages except API routes which work fine.

In contrast, my site runs perfectly with bun run build && wrangler pages dev. I have Cloudflare Pages server preset configured as noted in the Tanstack docs.

The error is with my code, b/c a minimal repro attempt runs fine, but I have many routes and the error message isn't helping me find it yet.

// console error
Failed to load resource: the server responded with a status of 503 (Server Unavailable)


503 Server Unavailable
7:26:55 PM [vite] (ssr) Error when evaluating SSR module $vinxi/handler/ssr: Cannot split a chunk that has already been edited (0:7 – "import.meta")
      at MagicString._splitChunk (file:///Users/me/project/node_modules/vite/dist/node/chunks/dep-B0fRERkQ.js:4815:10)
      at MagicString._split (file:///Users/me/project/node_modules/vite/dist/node/chunks/dep-B0fRERkQ.js:4805:43)
      at MagicString.update (file:///Users/me/project/node_modules/vite/dist/node/chunks/dep-B0fRERkQ.js:4547:8)
      at onIdentifier (file:///Users/me/project/node_modules/vite/dist/node/chunks/dep-B0fRERkQ.js:31459:11)
      at file:///Users/me/project/node_modules/vite/dist/node/chunks/dep-B0fRERkQ.js:31629:39
      at Array.forEach (<anonymous>)
      at walk (file:///Users/me/project/node_modules/vite/dist/node/chunks/dep-B0fRERkQ.js:31628:15)
      at ssrTransformScript (file:///Users/me/project/node_modules/vite/dist/node/chunks/dep-B0fRERkQ.js:31425:3)
      at async loadAndTransform (file:///Users/me/project/node_modules/vite/dist/node/chunks/dep-B0fRERkQ.j
Was this page helpful?