N
Nuxt3mo ago
Honkhonk

@nuxt/devtools always references old install, cannot run generate

Hey everyone, this is probably a very stupid problem, I'm not sure it has to do with Nuxt, but every time I try to run pnpm install in any nuxt project, or create a new nuxt project, I get the following error:
➜ nuxtConventionApp git:(master) ✗ pnpm install --force
 WARN  using --force I sure hope you know what you are doing
Lockfile is up to date, resolution step is skipped
Packages: +851
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Progress: resolved 851, reused 851, downloaded 0, added 851, done

> nuxt-app@ postinstall /media/kyle/Active/Code/convention-sales/nuxtConventionApp
> nuxt prepare

ℹ Using default Tailwind CSS file nuxt:tailwindcss 7:41:52 PM

ERROR Error while requiring module /home/kyle/.nvm/versions/node/v18.12.1/lib/node_modules/@nuxt/devtools/module.cjs: Error: Cannot find module '/home/kyle/.nvm/versions/node/v18.12.1/lib/node_modules/@nuxt/devtools/module.cjs' 7:41:52 PM
Require stack:
- /media/kyle/Active/Code/convention-sales/nuxtConventionApp/index.js


ERROR Cannot find module '/home/kyle/.nvm/versions/node/v18.12.1/lib/node_modules/@nuxt/devtools/module.cjs' 7:41:52 PM
Require stack:
- /media/kyle/Active/Code/convention-sales/nuxtConventionApp/index.js

Require stack:
- index.js
at Module._resolveFilename (node:internal/modules/cjs/loader:1248:15)
at Function.resolve (node:internal/modules/helpers:145:19)
at Function._resolve [as resolve] (node_modules/.pnpm/[email protected]/node_modules/jiti/dist/jiti.js:1:241814)
at resolveModule (node_modules/.pnpm/@[email protected][email protected][email protected]/node_modules/@nuxt/kit/dist/index.mjs:2234:29)
at requireModule (node_modules/.pnpm/@[email protected][email protected][email protected]/node_modules/@nuxt/kit/dist/index.mjs:2239:24)
at loadNuxtModuleInstance (node_modules/.pnpm/@[email protected][email protected][email protected]/node_modules/@nuxt/kit/dist/index.mjs:2518:92)
at async installModule (node_modules/.pnpm/@[email protected][email protected][email protected]/node_modules/@nuxt/kit/dist/index.mjs:2470:47)
at async initNuxt (node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]_fpweuryjbgsvqkmqqt5v74c5dy/node_modules/nuxt/dist/index.mjs:4506:5)
at async loadNuxt (node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]_fpweuryjbgsvqkmqqt5v74c5dy/node_modules/nuxt/dist/index.mjs:4673:5)
at async loadNuxt (node_modules/.pnpm/@[email protected][email protected][email protected]/node_modules/@nuxt/kit/dist/index.mjs:2664:19)



ERROR Cannot find module '/home/kyle/.nvm/versions/node/v18.12.1/lib/node_modules/@nuxt/devtools/module.cjs' 7:41:52 PM
Require stack:
- /media/kyle/Active/Code/convention-sales/nuxtConventionApp/index.js

 ELIFECYCLE  Command failed with exit code 1.
➜ nuxtConventionApp git:(master) ✗ pnpm install --force
 WARN  using --force I sure hope you know what you are doing
Lockfile is up to date, resolution step is skipped
Packages: +851
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Progress: resolved 851, reused 851, downloaded 0, added 851, done

> nuxt-app@ postinstall /media/kyle/Active/Code/convention-sales/nuxtConventionApp
> nuxt prepare

ℹ Using default Tailwind CSS file nuxt:tailwindcss 7:41:52 PM

ERROR Error while requiring module /home/kyle/.nvm/versions/node/v18.12.1/lib/node_modules/@nuxt/devtools/module.cjs: Error: Cannot find module '/home/kyle/.nvm/versions/node/v18.12.1/lib/node_modules/@nuxt/devtools/module.cjs' 7:41:52 PM
Require stack:
- /media/kyle/Active/Code/convention-sales/nuxtConventionApp/index.js


ERROR Cannot find module '/home/kyle/.nvm/versions/node/v18.12.1/lib/node_modules/@nuxt/devtools/module.cjs' 7:41:52 PM
Require stack:
- /media/kyle/Active/Code/convention-sales/nuxtConventionApp/index.js

Require stack:
- index.js
at Module._resolveFilename (node:internal/modules/cjs/loader:1248:15)
at Function.resolve (node:internal/modules/helpers:145:19)
at Function._resolve [as resolve] (node_modules/.pnpm/[email protected]/node_modules/jiti/dist/jiti.js:1:241814)
at resolveModule (node_modules/.pnpm/@[email protected][email protected][email protected]/node_modules/@nuxt/kit/dist/index.mjs:2234:29)
at requireModule (node_modules/.pnpm/@[email protected][email protected][email protected]/node_modules/@nuxt/kit/dist/index.mjs:2239:24)
at loadNuxtModuleInstance (node_modules/.pnpm/@[email protected][email protected][email protected]/node_modules/@nuxt/kit/dist/index.mjs:2518:92)
at async installModule (node_modules/.pnpm/@[email protected][email protected][email protected]/node_modules/@nuxt/kit/dist/index.mjs:2470:47)
at async initNuxt (node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]_fpweuryjbgsvqkmqqt5v74c5dy/node_modules/nuxt/dist/index.mjs:4506:5)
at async loadNuxt (node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]_fpweuryjbgsvqkmqqt5v74c5dy/node_modules/nuxt/dist/index.mjs:4673:5)
at async loadNuxt (node_modules/.pnpm/@[email protected][email protected][email protected]/node_modules/@nuxt/kit/dist/index.mjs:2664:19)



ERROR Cannot find module '/home/kyle/.nvm/versions/node/v18.12.1/lib/node_modules/@nuxt/devtools/module.cjs' 7:41:52 PM
Require stack:
- /media/kyle/Active/Code/convention-sales/nuxtConventionApp/index.js

 ELIFECYCLE  Command failed with exit code 1.
I do not have 18.12.1 installed anymore, and do not want to install it, but I did awhile ago. Do I need v18.12.1 or is this a config issue?
6 Replies
Honkhonk
HonkhonkOP3mo ago
To Clarify, I had used 18.12.1 to create this project. I have checked my path, removed and reinstalled nvm, cleaned my ~/.zshrc, restarted, tried other projects, etc. I have deleted node_modules, cleaned the pnpm cache, searched my entire harddrive for possible symlinks, everything I can possibly think of. I created a docker container using node:22-alpine, and was able to run the generate command, but for some reason, somewhere, something is trying to use an old version of nuxt/devtools and I absolutely cannot find where or why it would do that.
Honkhonk
HonkhonkOP3mo ago
I ran an strace and I can see it trying to access that file, but I have zero ideas as to why
Honkhonk
HonkhonkOP3mo ago
npx nuxt info
- Operating System: `Linux`
- Node Version: `v22.9.0`
- Nuxt Version: `3.13.2`
- CLI Version: `3.14.0`
- Nitro Version: `2.9.7`
- Package Manager: `[email protected]`
- Builder: `-`
- User Config: `-`
- Runtime Modules: `-`
- Build Modules: `-`
- Operating System: `Linux`
- Node Version: `v22.9.0`
- Nuxt Version: `3.13.2`
- CLI Version: `3.14.0`
- Nitro Version: `2.9.7`
- Package Manager: `[email protected]`
- Builder: `-`
- User Config: `-`
- Runtime Modules: `-`
- Build Modules: `-`
Honkhonk
HonkhonkOP3mo ago
This is set immediately in initNuxt, where could this possibly be coming from, lol...
export default defineNuxtConfig({
modules: [
'@nuxtjs/tailwindcss',
'@nuxt/test-utils/module'
]
})
export default defineNuxtConfig({
modules: [
'@nuxtjs/tailwindcss',
'@nuxt/test-utils/module'
]
})
No description
Honkhonk
HonkhonkOP3mo ago
Its coming from an rc file, but I absolutely deleted this file, so, the digging continues
No description
Honkhonk
HonkhonkOP3mo ago
Ok yep, it was .nuxtrc in my home folder. Hey! Lets spend 3 hours digging through source code instead of checking if that rm command really worked. Godspeed to whatever file was deleted on accident instead, I hope you were not needed.
No description
Want results from more Discord servers?
Add your server