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

Error while running next.js 14.2.4 in stackblitz environment

Open vladiulianbogdan opened this issue 1 year ago • 1 comments

Link to the code that reproduces this issue

https://stackblitz.com/edit/nextjs-3hmlb9?file=package.json

To Reproduce

  1. Go to this URL https://stackblitz.com/edit/nextjs-3hmlb9?file=package.json
  2. Make sure next version is 14.2.4
  3. Run npm run dev
  4. The output will be:
  ▲ Next.js 14.2.4
  - Local:        http://localhost:3000

 ✓ Starting...
   Downloading swc package @next/swc-wasm-nodejs...
 ⚠ Attempted to load @next/swc-linux-x64-gnu, but an error occurred: Cannot load native addon because loading addons is disabled: /home/projects/nextjs-3hmlb9/node_modules/@next/swc-linux-x64-gnu/next-swc.linux-x64-gnu.node
 ⚠ Attempted to load @next/swc-linux-x64-musl, but an error occurred: Cannot load native addon because loading addons is disabled: /home/projects/nextjs-3hmlb9/node_modules/@next/swc-linux-x64-musl/next-swc.linux-x64-musl.node
 ⨯ Failed to load SWC binary for linux/x64, see more info here: https://nextjs.org/docs/messages/failed-loading-swc
  1. Change the next version to 14.1.0 and run again npm install. Now npm run dev works well.

Current vs. Expected behavior

npm run dev should work in next.js 14.2.4 when running in Stackblitz environment.

Provide environment information

Operating System:
  Platform: linux
  Arch: x64
  Version: Ubuntu 20.04.0 LTS Fri Jun 28 2024 17:32:38 GMT+0300 (Eastern European Summer Time)
  Available memory (MB): NaN
  Available CPU cores: 8
Binaries:
  Node: 18.20.3
  npm: 10.2.3
  Yarn: 1.22.19
  pnpm: 8.15.6
Relevant Packages:
  next: 14.2.4 // Latest available version is detected (14.2.4).
  eslint-config-next: 13.5.1
  react: 18.2.0
  react-dom: 18.2.0
  typescript: 5.2.2
Next.js Config:
  output: N/A

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

Instrumentation, Testing, SWC

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

next start (local)

Additional context

No response

vladiulianbogdan avatar Jun 28 '24 14:06 vladiulianbogdan

Looks like its fixed on canary

https://x.com/huozhi/status/1806751723496653295?s=46&t=g7KkzH87K5uk5ICMNIWrdw

r34son avatar Jun 28 '24 23:06 r34son

Looks like its fixed on canary

https://x.com/huozhi/status/1806751723496653295?s=46&t=g7KkzH87K5uk5ICMNIWrdw

Indeed! Closing this as it has been fixed on canary, and will land on a stable release soon.

ztanner avatar Jul 03 '24 18:07 ztanner

This closed issue has been automatically locked because it had no new activity for 2 weeks. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.

github-actions[bot] avatar Jul 18 '24 00:07 github-actions[bot]

The fix is backport to 14.2.5

huozhi avatar Jul 18 '24 08:07 huozhi