Skip to content

Vite plugin obscuring error messages #10499

@vladmiller

Description

@vladmiller

What versions & operating system are you using?

npx envinfo --system --npmPackages '{wrangler,create-cloudflare,miniflare,@cloudflare/*}' --binaries
Need to install the following packages:
envinfo@7.14.0
Ok to proceed? (y) y

System:
OS: macOS 15.6
CPU: (8) arm64 Apple M2
Memory: 409.70 MB / 24.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 22.17.1 - ~/.nvm/versions/node/v22.17.1/bin/node
npm: 10.9.2 - ~/.nvm/versions/node/v22.17.1/bin/npm
pnpm: 10.15.0 - ~/.nvm/versions/node/v22.17.1/bin/pnpm
npmPackages:
@cloudflare/vite-plugin: ^1.0.12 => 1.12.1
wrangler: ^4.33.1 => 4.33.1

Please provide a link to a minimal reproduction

No response

Describe the Bug

Cloudflare vite plugin obscures error messages with

Error running module "
    at async ProxyServer.fetch (file:///Users/john/Projects/my-react-router-app/node_modules/.pnpm/miniflare@4.20250823.1/node_modules/miniflare/src/workers/core/proxy.worker.ts:174:11

It does not matter whether it's a syntax error or some code throwing an exception during start-up.

The way to reproduce:

  • pnpm create cloudflare@latest my-react-router-app --framework=react-router
  • Update any ts code to introduce syntax error, for example you can edit welcome.tsx like so
    • export function Welcome({ message }: { message: string }) {
      retu rn ( // <-- notice typo
         // 
  • Start the server and open http://localhost:5173/

Please provide any relevant error logs

No response

Metadata

Metadata

Assignees

Labels

bugSomething that isn't workingvite-pluginRelating to the `@cloudflare/vite-plugin` package

Type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions