Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing internal module 'internal/deps/node:stream' on any Nuxt command after trying to install a dependency #265

Closed
tomklino opened this issue Oct 26, 2023 · 3 comments

Comments

@tomklino
Copy link

tomklino commented Oct 26, 2023

Environment

npx nuxi info
Working directory: /home/----/workspace 11:38:38 PM
Nuxt project info: (copied to clipboard) 11:38:38 PM


  • Operating System: Linux
  • Node Version: v18.13.0
  • Nuxt Version: 3.8.0
  • CLI Version: 3.9.1
  • Nitro Version: 2.7.0
  • Package Manager: [email protected]
  • Builder: -
  • User Config: runtimeConfig, devtools, modules
  • Runtime Modules: @nuxtjs/[email protected], @nuxt/[email protected]
  • Build Modules: -

Reproduction

I'm not sure exactly what triggered this, I installed the following dependencies and then everything broke:

npm install @heroicons/vue@latest
npm install @headlessui/vue

Describe the bug

npm run dev no longer works, so as any other command, including trying to create a new nuxt project with npx nuxi@latest init workspace-notes-2. Getting the following error:

 ERROR  Missing internal module 'internal/deps/node:stream'                                                                                                                           9:52:53 PM

  at requireBuiltin (node:internal/bootstrap/loaders:364:19)
  at requireWithFallbackInDeps (node:internal/bootstrap/loaders:374:10)
  at fastify-busboy/lib/main.js (node:internal/deps/undici/undici:3491:26)
  at __require (node:internal/deps/undici/undici:4:50)
  at lib/fetch/body.js (node:internal/deps/undici/undici:4203:18)
  at __require (node:internal/deps/undici/undici:4:50)
  at lib/fetch/response.js (node:internal/deps/undici/undici:4577:49)
  at __require (node:internal/deps/undici/undici:4:50)
  at lib/fetch/index.js (node:internal/deps/undici/undici:9091:9)
  at __require (node:internal/deps/undici/undici:4:50) 

Additional context

Here is what I tried to fix it:

  • Removing node-modules and package-lock.json and running npm install
  • Reinstalling node and npm

From the end of the full error report:

225 timing command:install Completed in 13465ms
226 verbose stack Error: command failed
226 verbose stack     at ChildProcess.<anonymous> (/usr/share/nodejs/@npmcli/promise-spawn/lib/index.js:53:27)
226 verbose stack     at ChildProcess.emit (node:events:513:28)
226 verbose stack     at maybeClose (node:internal/child_process:1091:16)
226 verbose stack     at ChildProcess._handle.onexit (node:internal/child_process:302:5)
227 verbose cwd /home/----/workspace/workspace-notes
228 verbose Linux 6.5.6-1rodete2-amd64
229 verbose node v18.13.0
230 verbose npm  v9.2.0
231 error code 1
232 error path /home/----/workspace/workspace-notes
233 error command failed
234 error command sh -c nuxt prepare
235 verbose exit 1
236 timing npm Completed in 13507ms
237 verbose code 1
238 error A complete log of this run can be found in:
238 error     /home/----/.npm/_logs/2023-10-26T18_49_43_854Z-debug-0.log

Logs

No response

@github-actions
Copy link

Would you be able to provide a reproduction? 🙏

More info

Why do I need to provide a reproduction?

Reproductions make it possible for us to triage and fix issues quickly with a relatively small team. It helps us discover the source of the problem, and also can reveal assumptions you or we might be making.

What will happen?

If you've provided a reproduction, we'll remove the label and try to reproduce the issue. If we can, we'll mark it as a bug and prioritize it based on its severity and how many people we think it might affect.

If needs reproduction labeled issues don't receive any substantial activity (e.g., new comments featuring a reproduction link), we'll close them. That's not because we don't care! At any point, feel free to comment with a reproduction and we'll reopen it.

How can I create a reproduction?

We have a couple of templates for starting with a minimal reproduction:

👉 https://stackblitz.com/github/nuxt/starter/tree/v3-stackblitz
👉 https://codesandbox.io/s/github/nuxt/starter/v3-codesandbox

A public GitHub repository is also perfect. 👌

Please ensure that the reproduction is as minimal as possible. See more details in our guide.

You might also find these other articles interesting and/or helpful:

@danielroe danielroe transferred this issue from nuxt/nuxt Oct 27, 2023
@lukaszlew
Copy link

I've hit the same bug on unrelated react project.

@pi0
Copy link
Member

pi0 commented Nov 3, 2023

Quickly checking nuxi dist, we don't generate deps/node:stream anywhere. It seems a Node.js related bug fixing by upgrading to v20.9.0. (google/clasp#985 (comment))

In case you are still experiencing issue even after upgrading Node.js, please ping me to investigate ideally with a reproduction.

@pi0 pi0 closed this as not planned Won't fix, can't repro, duplicate, stale Nov 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants