首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >调试maven构建日志中的NPM故障

调试maven构建日志中的NPM故障
EN

Stack Overflow用户
提问于 2016-05-10 16:18:47
回答 1查看 172关注 0票数 0

我们使用Maven构建应用程序。后端是Java,但是我们使用frontend-maven-plugin来构建web应用程序。

它在本地运行非常可靠。然而,夜间竹子的工作经常失败。

代码语言:javascript
运行
复制
build   07-May-2016 23:03:03    [INFO] > phantomjs@1.9.18 install /home/bamboo/bamboo-agent-home/xml-data/build-dir/DDF-NGHT-JOB1/ddf/catalog/ui/search-ui/standard/node_modules/phantomjs
build   07-May-2016 23:03:03    [INFO] > node install.js
build   07-May-2016 23:03:03    [INFO] 
build   07-May-2016 23:03:04    [INFO] Downloading http://cnpmjs.org/downloads/phantomjs-1.9.8-linux-x86_64.tar.bz2
build   07-May-2016 23:03:04    [INFO] Saving to /tmp/phantomjs/phantomjs-1.9.8-linux-x86_64.tar.bz2
build   07-May-2016 23:03:04    [INFO] Receiving...
build   07-May-2016 23:04:06    [ERROR] 
build   07-May-2016 23:04:08    [ERROR] 
build   07-May-2016 23:04:11    [ERROR] 
build   07-May-2016 23:04:18    [ERROR] 
build   07-May-2016 23:06:37    [ERROR] 
build   07-May-2016 23:07:54    [ERROR] 
build   07-May-2016 23:07:59    [ERROR] 
build   07-May-2016 23:09:30    [INFO] 
build   07-May-2016 23:09:30    [INFO] Received 12854K total.
build   07-May-2016 23:09:30    [INFO] Extracting tar contents (via spawned process)
build   07-May-2016 23:09:32    [INFO] Removing /home/bamboo/bamboo-agent-home/xml-data/build-dir/DDF-NGHT-JOB1/ddf/catalog/ui/search-ui/standard/node_modules/phantomjs/lib/phantom
build   07-May-2016 23:09:32    [INFO] Copying extracted folder /tmp/phantomjs/phantomjs-1.9.8-linux-x86_64.tar.bz2-extract-1462687770261/phantomjs-1.9.8-linux-x86_64 -> /home/bamboo/bamboo-agent-home/xml-data/build-dir/DDF-NGHT-JOB1/ddf/catalog/ui/search-ui/standard/node_modules/phantomjs/lib/phantom
build   07-May-2016 23:09:32    [INFO] Writing location.js file
build   07-May-2016 23:09:32    [INFO] Done. Phantomjs binary available at /home/bamboo/bamboo-agent-home/xml-data/build-dir/DDF-NGHT-JOB1/ddf/catalog/ui/search-ui/standard/node_modules/phantomjs/lib/phantom/bin/phantomjs
build   07-May-2016 23:09:32    [ERROR] npm WARN deprecated npmconf@2.1.2: this package has been reintegrated into npm and is now out of date with respect to npm
build   07-May-2016 23:09:32    [ERROR] npm ERR! Linux 4.4.5-15.26.amzn1.x86_64
build   07-May-2016 23:09:32    [ERROR] npm ERR! argv "/home/bamboo/bamboo-agent-home/xml-data/build-dir/DDF-NGHT-JOB1/ddf/catalog/ui/search-ui/standard/node/node" "/home/bamboo/bamboo-agent-home/xml-data/build-dir/DDF-NGHT-JOB1/ddf/catalog/ui/search-ui/standard/node/node_modules/npm/bin/npm-cli.js" "install"
build   07-May-2016 23:09:32    [ERROR] npm ERR! node v4.3.1
build   07-May-2016 23:09:32    [ERROR] npm ERR! npm  v2.14.12
build   07-May-2016 23:09:32    [ERROR] npm ERR! code ECONNRESET
build   07-May-2016 23:09:32    [ERROR] npm ERR! errno ECONNRESET
build   07-May-2016 23:09:32    [ERROR] npm ERR! syscall read
build   07-May-2016 23:09:32    [ERROR] npm ERR! network read ECONNRESET
build   07-May-2016 23:09:32    [ERROR] npm ERR! network This is most likely not a problem with npm itself
build   07-May-2016 23:09:32    [ERROR] npm ERR! network and is related to network connectivity.
build   07-May-2016 23:09:32    [ERROR] npm ERR! network In most cases you are behind a proxy or have bad network settings.
build   07-May-2016 23:09:32    [ERROR] npm ERR! network 
build   07-May-2016 23:09:32    [ERROR] npm ERR! network If you are behind a proxy, please make sure that the
build   07-May-2016 23:09:32    [ERROR] npm ERR! network 'proxy' config is set properly.  See: 'npm help config'

我们不是一个代理人,长城,或诸如此类的。如果是的话,这些失败就会更容易重复。

我问过一个同事。他说,当npm运行这些模块的安装脚本时,脚本试图从整个网络下载东西。如果脚本中的站点不可用,则失败。

我想核实一下。我无法访问npm-调试器日志,因为竹子没有保留它。我怎么弄清楚到底是怎么回事?

昨晚,它似乎在试图安装which npm模块时窒息了,这是phantomjs的一个依赖项。

代码语言:javascript
运行
复制
build   07-May-2016 23:09:34    [INFO] phantomjs@1.9.18 node_modules/phantomjs
build   07-May-2016 23:09:34    [INFO] ├── progress@1.1.8
build   07-May-2016 23:09:34    [INFO] ├── kew@0.4.0
build   07-May-2016 23:09:34    [ERROR] npm ERR! argv "/home/bamboo/bamboo-agent-home/xml-data/build-dir/DDF-NGHT-JOB1/ddf/catalog/ui/search-ui/standard/node/node" "/home/bamboo/bamboo-agent-home/xml-data/build-dir/DDF-NGHT-JOB1/ddf/catalog/ui/search-ui/standard/node/node_modules/npm/bin/npm-cli.js" "install"
build   07-May-2016 23:09:34    [INFO] ├── request-progress@0.3.1 (throttleit@0.0.2)
build   07-May-2016 23:09:34    [INFO] ├── adm-zip@0.4.4
build   07-May-2016 23:09:34    [INFO] ├── request@2.42.0 (forever-agent@0.5.2, aws-sign2@0.5.0, tunnel-agent@0.4.3, caseless@0.6.0, oauth-sign@0.4.0, stringstream@0.0.5, json-stringify-safe@5.0.1, tough-cookie@2.2.2, mime-types@1.0.2, qs@1.2.2, node-uuid@1.4.7, http-signature@0.10.1, form-data@0.1.4, bl@0.9.5, hawk@1.1.1)
build   07-May-2016 23:09:34    [INFO] ├── npmconf@2.1.1 (ini@1.3.4, uid-number@0.0.5, inherits@2.0.1, once@1.3.3, semver@4.3.6, osenv@0.1.3, nopt@3.0.6, config-chain@1.1.10, mkdirp@0.5.1)
build   07-May-2016 23:09:34    [INFO] └── fs-extra@0.23.1 (path-is-absolute@1.0.0, graceful-fs@4.1.4, jsonfile@2.3.0, rimraf@2.5.2)
build   07-May-2016 23:09:34    [ERROR] npm ERR! node v4.3.1
build   07-May-2016 23:09:34    [ERROR] npm ERR! npm  v2.14.12
build   07-May-2016 23:09:34    [ERROR] 
build   07-May-2016 23:09:34    [ERROR] npm ERR! Callback called more than once.
build   07-May-2016 23:09:34    [ERROR] npm ERR! 
build   07-May-2016 23:09:34    [ERROR] npm ERR! If you need help, you may report this error at:
build   07-May-2016 23:09:34    [ERROR] npm ERR!     <https://github.com/npm/npm/issues>
build   07-May-2016 23:09:34    [ERROR] 
build   07-May-2016 23:09:34    [ERROR] npm ERR! Please include the following file with any support request:
build   07-May-2016 23:09:34    [ERROR] npm ERR!     /home/bamboo/bamboo-agent-home/xml-data/build-dir/DDF-NGHT-JOB1/ddf/catalog/ui/search-ui/standard/npm-debug.log
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2016-05-16 10:46:29

一个补丁已经提交到节点>=4.4、>=5.4和>=6中,它解决了ECONNRESET问题。尝试将节点升级到上述版本。

有关详细信息,请参阅这里

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/37143982

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档