nodejs / node

Node.js JavaScript runtime ✨🐢🚀✨
https://nodejs.org
Other
108.11k stars 29.86k forks source link

hexo server error #46637

Closed jiehua1995 closed 1 year ago

jiehua1995 commented 1 year ago

Version

v16.14.0

Platform

MINGW64_NT-10.0-19044 3.3.3-341.x86_64 2022-01-17 11:45 UTC x86_64

Subsystem

hexo-site

What steps will reproduce the bug?

$ hexo s
ERROR Cannot find module 'hexo' from 'C:\GitHub\note'
ERROR Local hexo loading failed in C:\GitHub\note
ERROR Try running: 'rm -rf node_modules && npm install --force'
$ npm ls
hexo-site@0.0.0 C:\GitHub\note
├── UNMET DEPENDENCY hexo-generator-archive@^2.0.0
├── UNMET DEPENDENCY hexo-generator-category@^2.0.0
├── UNMET DEPENDENCY hexo-generator-index@^3.0.0
├── UNMET DEPENDENCY hexo-generator-tag@^2.0.0
├── UNMET DEPENDENCY hexo-renderer-ejs@^2.0.0
├── UNMET DEPENDENCY hexo-renderer-marked@^6.0.0
├── UNMET DEPENDENCY hexo-renderer-stylus@^2.1.0
├── UNMET DEPENDENCY hexo-server@^3.0.0
├── UNMET DEPENDENCY hexo-theme-landscape@^0.0.3
└── UNMET DEPENDENCY hexo@^6.3.0

npm ERR! code ELSPROBLEMS
npm ERR! missing: hexo-generator-archive@^2.0.0, required by hexo-site@0.0.0
npm ERR! missing: hexo-generator-category@^2.0.0, required by hexo-site@0.0.0
npm ERR! missing: hexo-generator-index@^3.0.0, required by hexo-site@0.0.0
npm ERR! missing: hexo-generator-tag@^2.0.0, required by hexo-site@0.0.0
npm ERR! missing: hexo-renderer-ejs@^2.0.0, required by hexo-site@0.0.0
npm ERR! missing: hexo-renderer-marked@^6.0.0, required by hexo-site@0.0.0
npm ERR! missing: hexo-renderer-stylus@^2.1.0, required by hexo-site@0.0.0
npm ERR! missing: hexo-server@^3.0.0, required by hexo-site@0.0.0
npm ERR! missing: hexo-theme-landscape@^0.0.3, required by hexo-site@0.0.0
npm ERR! missing: hexo@^6.3.0, required by hexo-site@0.0.0

How often does it reproduce? Is there a required condition?

I have this error in Linux, Windows, and MacOS systems.

What is the expected behavior?

No response

What do you see instead?

It seems the npm has some problem.

Additional information

No response

jiehua1995 commented 1 year ago

Sorry, it is solved by

npm -g update