标签:npm getaddrinfo vue run ERR -- dev js 报错
报错信息如下:
npm run start
> vocalprint@1.0.0 start /Users/mengzhichao/Desktop/cc/4pd/ie
> npm run dev
> vocalprint@1.0.0 dev /Users/mengzhichao/Desktop/cc/4pd/ie
> webpack-dev-server --inline --progress --config build/webpack.dev.conf.js
10% building modules 1/1 modules 0 activeevents.js:377
throw er; // Unhandled 'error' event
^
Error: getaddrinfo ENOTFOUND x86_64-apple-darwin13.4.0
at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:69:26)
Emitted 'error' event on Server instance at:
at GetAddrInfoReqWrap.doListen [as callback] (net.js:1502:12)
at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:69:17) {
errno: -3008,
code: 'ENOTFOUND',
syscall: 'getaddrinfo',
hostname: 'x86_64-apple-darwin13.4.0'
}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! vocalprint@1.0.0 dev: `webpack-dev-server --inline --progress --config build/webpack.dev.conf.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the vocalprint@1.0.0 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! /Users/mengzhichao/.npm/_logs/2022-03-18T08_58_27_001Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! vocalprint@1.0.0 start: `npm run dev`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the vocalprint@1.0.0 start 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/mengzhichao/.npm/_logs/2022-03-18T08
!!!重点报错信息在这!!!
Error: getaddrinfo ENOTFOUND x86_64-apple-darwin13.4.0
at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:69:26)
解决方案1:
在/etc/hosts里面添加
sudo vi /etc/hosts
127.0.0.1 x86_64-apple-darwin13.4.0
npm run start 启动成功
解决方案2
在当前命令行窗口执行
unset HOST
npm run start
即可成功!!!
标签:npm,getaddrinfo,vue,run,ERR,--,dev,js,报错
来源: https://blog.csdn.net/true1cc/article/details/123579970
本站声明:
1. iCode9 技术分享网(下文简称本站)提供的所有内容,仅供技术学习、探讨和分享;
2. 关于本站的所有留言、评论、转载及引用,纯属内容发起人的个人观点,与本站观点和立场无关;
3. 关于本站的所有言论和文字,纯属内容发起人的个人观点,与本站观点和立场无关;
4. 本站文章均是网友提供,不完全保证技术分享内容的完整性、准确性、时效性、风险性和版权归属;如您发现该文章侵犯了您的权益,可联系我们第一时间进行删除;
5. 本站为非盈利性的个人网站,所有内容不会用来进行牟利,也不会利用任何形式的广告来间接获益,纯粹是为了广大技术爱好者提供技术内容和技术思想的分享性交流网站。