Environment
- Linux
- Node 24.21.0
- pnpm 12.6.0
nuxt-nightly@5.0.0-29841792.9ceeba8c (Nitro 3.0.260903-beta, Vite 8.3.1)
- Resolved CLI:
@nuxt/cli-nightly@4.0.0-20260928-072145-54eebce
Minimal reproduction
package.json:
{
"name": "nuxt5-cli-repro",
"private": true,
"type": "module",
"scripts": { "dev": "nuxt dev" },
"dependencies": {
"nuxt": "npm:nuxt-nightly@5.0.0-29841792.9ceeba8c"
}
}
nuxt.config.ts:
export default defineNuxtConfig({
compatibilityDate: '2025-07-15'
})
app/app.vue:
<template>
<NuxtWelcome />
</template>
Run pnpm install && CI=1 pnpm run dev, then request http://localhost:3000/.
Actual result
The CLI prints Ready, but the page returns HTTP 500. The dev log reports:
Error: This module cannot be imported in server runtime.
[importing `@nuxt/cli-nightly/runtime/dev-close-sockets.mjs` from `#nitro/virtual/plugins`]
Suggestions:
- These are build-time only packages and cannot be used at runtime.
The error comes from impound through Vite's vite:import-analysis. The generated #nitro/virtual/plugins module imports @nuxt/cli-nightly/runtime/dev-close-sockets.mjs.
I reproduced this in a fresh temporary project with no Nuxt modules or application logic. It also occurred in an app with @nuxtjs/i18n, but i18n is not required to trigger it.
Expected result
nuxt dev should serve the minimal welcome page with HTTP 200.
Possibly related: #1570 added runtime/dev-close-sockets.mjs to the CLI. Its linked issue #1531 concerns shutdown, whereas this is a startup/server runtime import failure.
Environment
nuxt-nightly@5.0.0-29841792.9ceeba8c(Nitro 3.0.260903-beta, Vite 8.3.1)@nuxt/cli-nightly@4.0.0-20260928-072145-54eebceMinimal reproduction
package.json:{ "name": "nuxt5-cli-repro", "private": true, "type": "module", "scripts": { "dev": "nuxt dev" }, "dependencies": { "nuxt": "npm:nuxt-nightly@5.0.0-29841792.9ceeba8c" } }nuxt.config.ts:app/app.vue:Run
pnpm install && CI=1 pnpm run dev, then requesthttp://localhost:3000/.Actual result
The CLI prints
Ready, but the page returns HTTP 500. The dev log reports:The error comes from
impoundthrough Vite'svite:import-analysis. The generated#nitro/virtual/pluginsmodule imports@nuxt/cli-nightly/runtime/dev-close-sockets.mjs.I reproduced this in a fresh temporary project with no Nuxt modules or application logic. It also occurred in an app with
@nuxtjs/i18n, but i18n is not required to trigger it.Expected result
nuxt devshould serve the minimal welcome page with HTTP 200.Possibly related: #1570 added
runtime/dev-close-sockets.mjsto the CLI. Its linked issue #1531 concerns shutdown, whereas this is a startup/server runtime import failure.