Heroku部署错误与node.js
应用程序在node.js中编程,并使用socket.io实时请求。
该应用程序工作正常,但今天我得到这个无限的错误:
2015-10-08T08:31:37.477080+00:00 app[web.1]: Prevented node from exit... 2015-10-08T08:31:37.477495+00:00 app[web.1]: TypeError: Cannot read property 'length' of undefined 2015-10-08T08:31:37.477496+00:00 app[web.1]: at onwriteDrain (_stream_writable.js:354:12) 2015-10-08T08:31:37.477497+00:00 app[web.1]: at afterWrite (_stream_writable.js:344:5) 2015-10-08T08:31:37.477498+00:00 app[web.1]: at wrapped (/app/node_modules/newrelic/lib/transaction/tracer/index.js:157:28) 2015-10-08T08:31:37.477498+00:00 app[web.1]: at doNTCallback0 (node.js:408:9) 2015-10-08T08:31:37.477499+00:00 app[web.1]: at Immediate._tickCallback [as _onImmediate] (node.js:337:13) 2015-10-08T08:31:37.477500+00:00 app[web.1]: at processImmediate [as _immediateCallback] (timers.js:374:17) 2015-10-08T08:31:37.477873+00:00 app[web.1]: TypeError: Cannot read property 'length' of undefined 2015-10-08T08:31:37.477503+00:00 app[web.1]: Prevented node from exit... 2015-10-08T08:31:37.477875+00:00 app[web.1]: at onwriteDrain (_stream_writable.js:354:12) 2015-10-08T08:31:37.477875+00:00 app[web.1]: at afterWrite (_stream_writable.js:344:5) 2015-10-08T08:31:37.477876+00:00 app[web.1]: at wrapped (/app/node_modules/newrelic/lib/transaction/tracer/index.js:157:28) 2015-10-08T08:31:37.477877+00:00 app[web.1]: at Immediate._tickCallback [as _onImmediate] (node.js:337:13) 2015-10-08T08:31:37.477877+00:00 app[web.1]: at doNTCallback0 (node.js:408:9) 2015-10-08T08:31:37.477878+00:00 app[web.1]: at processImmediate [as _immediateCallback] (timers.js:374:17) 2015-10-08T08:31:37.477900+00:00 app[web.1]: Prevented node from exit...
任何人都可以帮忙!
我会感激的,谢谢。
问题是来自npm的“request”包,它与node.js的最后一个版本不兼容。
所以我明确在package.js中添加版本
"engines": { "node": "0.10.x" },
现在一切正常。 谢谢
- Heroku Stormpath Unresponsive注册页面
- 在heroku上集成博客和node.js应用程序
- 我可以在Heroku上使用Bower和Rails,并且仍然保持Gower的bower_components目录不变?
- 如何在node.js app heroku中访问.env文件中的variables
- socketsio上heroku
- 无法在heroku上启动gunicorn(Django Node应用程序)错误:正在使用的连接:('0.0.0.0',46831)
- node.js heroku – app / web.1:错误:没有指定模板
- Firebase身份validation失败节点JS:NotAuthorizedError
- 多个Node.js“应用程序”在一个服务器文件不好的做法?