next.js icon indicating copy to clipboard operation
next.js copied to clipboard

Can't run application with any custom SWC plugin

Open kevva opened this issue 1 year ago • 0 comments

Link to the code that reproduces this issue

https://github.com/kevva/next-bugs/tree/swc-plugins

To Reproduce

  1. Run npm run dev (or npm run build) and you should see an error

Current vs. Expected behavior

Current behaviour

When running the app using next dev or building using next build with a custom SWC plugin currently produces an error saying:

thread '<unnamed>' panicked at /Users/geist/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wasmer-wasix-0.18.0/src/runtime/task_manager/tokio.rs:105:19:
there is no reactor running, must be called from the context of a Tokio 1.x runtime
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Expected behaviour

The application starts or builds successfully.

Provide environment information

Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 23.2.0: Wed Nov 15 21:53:18 PST 2023; root:xnu-10002.61.3~2/RELEASE_ARM64_T6000
Binaries:
  Node: 18.17.1
  npm: 10.2.4
  Yarn: 1.22.21
  pnpm: N/A
Relevant Packages:
  next: 14.1.1-canary.54 // Latest available version is detected (14.1.1-canary.54).
  eslint-config-next: 14.1.1-canary.54
  react: 18.2.0
  react-dom: 18.2.0
  typescript: 5.3.3
Next.js Config:
  output: N/A

Which area(s) are affected? (Select all that apply)

SWC transpilation

Which stage(s) are affected? (Select all that apply)

next dev (local), next build (local)

Additional context

This was introduced in https://github.com/vercel/next.js/releases/tag/v14.1.1-canary.52.

kevva avatar Feb 15 '24 09:02 kevva