解决 This is probably not a problem with npm. There is likely additional logging output above.

简介: 解决 This is probably not a problem with npm. There is likely additional logging output above.
  • 在执行 npm run serve 运行项目的时候报错:
dengzemiaodeMacBook-Pro:lianshan_vue dengzemiao$ npm run serve
......
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! lianshan@2.0.0 serve: `vue-cli-service serve`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the lianshan@2.0.0 serve script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/dengzemiao/.npm/_logs/2021-01-14T06_10_01_084Z-debug.log
  • 如果出现这种报错情况,需要重新安装 node_modules 文件夹中的内容 但是在安装前,要把之前的内容都清空掉。
  • 其实大多数的主要问题是 package-lock.json 这个文件,一般使用 1、2、4 步就够了,如果不行在重新 1、2、3、4 步,因为使用了 第3步,在 $ npm install 安装会要点时间,相对较慢。
  • 步骤如下:
    1、首先删除 node_modules,可以命令行删除,也可以手动右键删除文件夹。
$ rmdir /s/q node_modules
  • 2、删除 package-lock.json 文件
    3、运行命令
$ npm cache clean --force
  • 4、重新加载
$ npm install
相关文章
ERROR: No matching distribution found for gradio>=3.23
该博客文章提供了解决使用pip安装gradio版本3.23时出现的"No matching distribution found"错误的步骤,包括从官网下载相应的whl文件并手动安装。
ERROR: No matching distribution found for gradio>=3.23
|
5月前
|
JavaScript
Parsing error: No Babel config file detected for 。。
Parsing error: No Babel config file detected for 。。
122 3
|
5月前
|
JavaScript
解决报错did you register the component correctly? For recursive components, make sure to provide the “na
解决报错did you register the component correctly? For recursive components, make sure to provide the “na
|
5月前
|
资源调度
Yarn install 报错 Resolving packages... [2/4] Fetching packages... info There appears to be trouble wi
Yarn install 报错 Resolving packages... [2/4] Fetching packages... info There appears to be trouble wi
325 0
|
10月前
Error: Plugin/Preset files are not allowed to export objects, only functions……
Error: Plugin/Preset files are not allowed to export objects, only functions……
|
开发工具
WARNING: library configuration mismatch
WARNING: library configuration mismatch
295 0
|
Java Linux
error: Failed dependencies: libjvm.so()(64bit) is needed by (installed)
error: Failed dependencies: libjvm.so()(64bit) is needed by (installed)
error: Failed dependencies: libjvm.so()(64bit) is needed by (installed)
No matching configuration of project :libusb was found.
No matching configuration of project :libusb was found.
597 0
configure: error: Library requirements (libpcre >= 7.8) not met
configure: error: Library requirements (libpcre >= 7.8) not met
131 0
configure: error: Package requirements (commoncpp 6.2.2) were not met
configure: error: Package requirements (commoncpp 6.2.2) were not met
81 0