Skip to content

Nuxt vite_node invalidates gives 500 Error #31429

@1MisterT

Description

@1MisterT

Environment

  • Operating System: Linux
  • Node Version: v22.11.0
  • Nuxt Version: 3.16.0
  • CLI Version: 3.22.5
  • Nitro Version: 2.11.6
  • Package Manager: pnpm@9.14.4
  • Builder: -
  • User Config: modules, css, future, robots, site, sitemap, app, runtimeConfig, auth, imports, components, $development, $production, ui, viewport, hooks, compatibilityDate, devtools
  • Runtime Modules: @nuxt/ui@3.0.0-beta.3, nuxt-viewport@2.2.0, @vueuse/nuxt@11.3.0, @nuxtjs/sitemap@7.2.7, @nuxtjs/robots@5.2.6, @sidebase/nuxt-auth@0.10.1
  • Build Modules: -

Reproduction

normal use

Describe the bug

When using nuxt normally and hot reloading from time to time. At some point the given error comes up on the website and in the console. Restarting nuxt will solve this bug temporarily but after some time it keeps happening again. It's seems to be only happening in development.

Additional context

Image

Logs

[unhandledRejection] connect EADDRNOTAVAIL 127.0.0.1:32835 - Local (0.0.0.0:0)                                                                       11:14:27 AM

    at internalConnect (node:net:1097:16)
    at defaultTriggerAsyncIdScope (node:internal/async_hooks:464:18)
    at node:net:1327:9
    at process.processTicksAndRejections (node:internal/process/task_queues:85:11)


 ERROR  [request error] [unhandled] [GET] http://localhost:3000/albums/finn-test


ℹ Error: [GET] "http://127.0.0.1:32835/__nuxt_vite_node__/invalidates": <no response> fetch failed

 ⁃ at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
 ⁃ at async $fetchRaw2 (node_modules/.pnpm/ofetch@1.4.1/node_modules/ofetch/dist/shared/ofetch.03887fc3.mjs:270:14)

   265 ┃          await callHooks(
   266 ┃            context,
   267 ┃            context.options.onRequestError
   268 ┃          );
   269 ┃        }
 ❯ 270 ┃        return await onError(context);
   271 ┃      } finally {
   272 ┃        if (abortTimeout) {
   273 ┃          clearTimeout(abortTimeout);
   274 ┃        }
   275 ┃      }

 ⁃ at async $fetch2 (node_modules/.pnpm/ofetch@1.4.1/node_modules/ofetch/dist/shared/ofetch.03887fc3.mjs:316:15)
 ⁃ at async default (node_modules/.pnpm/@nuxt+vite-builder@3.16.0_@types+node@22.13.10_eslint@9.22.0_jiti@2.4.2__lightningcss@1.29.2__q3uqehtdb7bjpxzyrfsc6xlhim/node_modules/@nuxt/vite-builder/dist/runtime/vite-node.mjs:23:23)
 ⁃ at async Object.renderToString (node_modules/.pnpm/vue-bundle-renderer@2.1.1/node_modules/vue-bundle-renderer/dist/runtime.mjs:173:19)
 ⁃ at async Object.render (node_modules/.pnpm/nuxt@3.16.0_@parcel+watcher@2.5.1_@types+node@22.13.10_db0@0.3.1_eslint@9.22.0_jiti@2.4.2__io_gfija2yyyxqt3oafwjkz4e3aki/node_modules/nuxt/dist/core/runtime/nitro/handlers/renderer.js:121:21)
 ⁃ at async Object.handler (node_modules/.pnpm/nitropack@2.11.6_typescript@5.8.2/node_modules/nitropack/dist/runtime/internal/renderer.mjs:25:22)
 ⁃ (async file://node_modules/.pnpm/h3@1.15.1/node_modules/h3/dist/index.mjs:2009:19)
 ⁃ at async Object.callAsync (node_modules/.pnpm/unctx@2.4.1/node_modules/unctx/dist/index.mjs:72:16)
 ⁃ at async Server.toNodeHandle (node_modules/.pnpm/h3@1.15.1/node_modules/h3/dist/index.mjs:2301:7)

[CAUSE]
TypeError {
  stack: 'fetch failed\n' +
  '    at node:internal/deps/undici/undici:13392:13\n' +
  '    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n' +
  'at async $fetchRaw2 (./node_modules/.pnpm/ofetch@1.4.1/node_modules/ofetch/dist/shared/ofetch.03887fc3.mjs:258:26)\n' +
  'at async $fetchRaw2 (./node_modules/.pnpm/ofetch@1.4.1/node_modules/ofetch/dist/shared/ofetch.03887fc3.mjs:270:14)\n' +
  'at async $fetch2 (./node_modules/.pnpm/ofetch@1.4.1/node_modules/ofetch/dist/shared/ofetch.03887fc3.mjs:316:15)\n' +
  'at async default (./node_modules/.pnpm/@nuxt+vite-builder@3.16.0_@types+node@22.13.10_eslint@9.22.0_jiti@2.4.2__lightningcss@1.29.2__q3uqehtdb7bjpxzyrfsc6xlhim/node_modules/@nuxt/vite-builder/dist/runtime/vite-node.mjs:23:23)\n' +
  'at async Object.renderToString (./node_mod'... 710 more characters,
  message: 'fetch failed',
  cause: Error {
    stack: 'connect EADDRNOTAVAIL 127.0.0.1:32835 - Local (0.0.0.0:0)\n' +
    '    at internalConnect (node:net:1097:16)\n' +
    '    at defaultTriggerAsyncIdScope (node:internal/async_hooks:464:18)\n' +
    '    at node:net:1327:9\n' +
    '    at process.processTicksAndRejections (node:internal/process/task_queues:85:11)',
    message: 'connect EADDRNOTAVAIL 127.0.0.1:32835 - Local (0.0.0.0:0)',
    errno: -99,
    code: 'EADDRNOTAVAIL',
    syscall: 'connect',
    address: '127.0.0.1',
    port: 32835,
  },
}

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions