Reputation: 1
node:internal/modules/cjs/loader:1146 throw err; ^
Error: Cannot find module 'C:\Program Files\nodejs\node_modules\npm\bin\node_modules\npm\bin\npm-cli.js' at Module._resolveFilename (node:internal/modules/cjs/loader:1143:15) at Module._load (node:internal/modules/cjs/loader:984:27) at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:135:12) at node:internal/main/run_main_module:28:49 { code: 'MODULE_NOT_FOUND', requireStack: [] }
Node.js v20.12.2 So i've been getting this error for a whole day now and it's Important that u should know i've tried setting up the path in environment variables and reinstalled node a 100 times, tried putting this problem in ChatGPT but no answer there. I've also checked the path C:\Program Files\nodejs\node_modules\npm\bin\node_modules\npm\bin\npm-cli.js and the module is present there but the system is not reading the module Please solve this as my internship depends on this npm
Error: Cannot find module 'C:\Program Files\nodejs\node_modules\npm\bin\node_modules\npm\bin\npm-cli.js' at Module._resolveFilename (node:internal/modules/cjs/loader:1143:15) at Module._load (node:internal/modules/cjs/loader:984:27) at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:135:12) at node:internal/main/run_main_module:28:49 { code: 'MODULE_NOT_FOUND', requireStack: [] }
Node.js v20.12.2
Upvotes: 0
Views: 690
Reputation: 1
Soo my problem got fixed automatically when I reinstalled node for the last time and set the path in environment variables before leaving office, when I got home I checked once again and it was fixed idk how or why
Upvotes: 0