npm install时候,报错 cb() never called!

问题:

E:\project\web>npm install
npm WARN tar zlib error: unexpected end of file
npm ERR! cb() never called!

npm ERR! This is an error with npm itself. Please report this error at:
npm ERR!     <https://github.com/npm/npm/issues>

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\gYS2262\AppData\Roaming\npm-cache\_logs\2018-12-10T03_01_24_886Z-debug.log

解决方案:npm cache clean -f       (清除npm缓存)

E:\project\web>npm cache clean -f
npm WARN using --force I sure hope you know what you are doing.

E:\project\web>npm install

> [email protected] install E:\project\rcms_web\node_modules\node-sass
> node scripts/install.js

Cached binary found at C:\Users\gYS2262\AppData\Roaming\npm-cache\node-sass\4.9.2\win32-x64-57_binding.node

> [email protected] postinstall E:\project\rcms_web\node_modules\swiper
> node -e "console.log('\u001b[35m\u001b[1mLove Swiper? Support Vladimir\'s work by donating or pledging on patreon:\u001b[22m\u001b[39m\n > \u001b[32mhttps://patreon.com/vladimirkharlampidi\u001b[0m\n')"

Love Swiper? Support Vladimir's work by donating or pledging on patreon:
 > https://patreon.com/vladimirkharlampidi


> [email protected] postinstall E:\project\rcms_web\node_modules\webpack\node_modules\uglifyjs-webpack-plugin
> node lib/post_install.js


> [email protected] postinstall E:\project\rcms_web\node_modules\node-sass
> node scripts/build.js

Binary found at E:\project\rcms_web\node_modules\node-sass\vendor\win32-x64-57\binding.node
Testing binary
Binary is fine
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

added 1629 packages in 415.69s

E:\project\web>npm run dev

> [email protected] dev E:\project\rcms_web
> webpack-dev-server --inline --progress --config build/webpack.dev.conf.js

 10% building modules 1/1 modules 0 activeevents.js:183
      throw er; // Unhandled 'error' event
      ^

Error: listen EADDRNOTAVAIL 192.168.76.89:8888
    at Object._errnoException (util.js:992:11)
    at _exceptionWithHostPort (util.js:1014:20)
    at Server.setupListenHandle [as _listen2] (net.js:1338:19)
    at listenInCluster (net.js:1396:12)
    at doListen (net.js:1505:7)
    at _combinedTickCallback (internal/process/next_tick.js:141:11)
    at process._tickCallback (internal/process/next_tick.js:180:9)
    at Function.Module.runMain (module.js:695:11)
    at startup (bootstrap_node.js:191:16)
    at bootstrap_node.js:612:3
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] dev: `webpack-dev-server --inline --progress --config build/webpack.dev.conf.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] dev 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!     C:\Users\gYS2262\AppData\Roaming\npm-cache\_logs\2018-12-10T03_12_55_056Z-debug.log

E:\project\web>npm run dev

> [email protected] dev E:\project\rcms_web
> webpack-dev-server --inline --progress --config build/webpack.dev.conf.js

 95% emitting

 DONE  Compiled successfully in 19343ms                                                                                                                                                                                                                                                                  11:13:44


 I  Your application is running here: http://192.168.77.32:8090
 

猜你喜欢

转载自blog.csdn.net/weixin_40098371/article/details/84937012
今日推荐