我最近将早午餐和相关库(例如,uglify-js-brunch)升级到1.7.x.当推送到Heroku时,我得到下面粘贴的错误。关于如何解决这个问题的任何线索?
谢谢!
-----> Installing dependencies
> xxxx@0.0.1 postinstall /tmp/build_d24a4120-fea7-4048-bddb-66be19b378f0
> brunch build --production
/tmp/build_d24a4120-fea7-4048-bddb-66be19b378f0/node_modules/uglify-js-brunch/lib/index.js:48
data: optimized.code
^
TypeError: Cannot read property 'code' of undefined
at UglifyMinifier.module.exports.UglifyMinifier.optimize (/tmp/build_d24a4120-fea7-4048-bddb-66be19b378f0/node_modules/uglify-js-brunch/lib/index.js:48
:24)
at /tmp/build_d24a4120-fea7-4048-bddb-66be19b378f0/node_modules/brunch/lib/fs_utils/generate.js:220:25
at fn (/tmp/build_d24a4120-fea7-4048-bddb-66be19b378f0/node_modules/brunch/node_modules/async-waterfall/index.js:19:24)
at Object._onImmediate (/tmp/build_d24a4120-fea7-4048-bddb-66be19b378f0/node_modules/brunch/node_modules/async-waterfall/index.js:58:22)
at processImmediate [as _immediateCallback] (timers.js:330:15)
npm ERR! xxxx@0.0.1 postinstall: `brunch build --production`
npm ERR! Exit status 8
npm ERR!
npm ERR! Failed at the xxxx@0.0.1 postinstall script.
npm ERR! This is most likely a problem with the xxxx package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! brunch build --production
npm ERR! You can get their info via:
npm ERR! npm owner ls xxxx
npm ERR! There is likely additional logging output above.
npm ERR! System Linux 3.8.11-ec2
npm ERR! command "/tmp/build_d24a4120-fea7-4048-bddb-66be19b378f0/vendor/node/bin/node" "/tmp/build_d24a4120-fea7-4048-bddb-66be19b378f0/vendor/node/bin/np
m" "install" "--production"
npm ERR! cwd /tmp/build_d24a4120-fea7-4048-bddb-66be19b378f0
npm ERR! node -v v0.10.22
npm ERR! npm -v 1.3.14
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /tmp/build_d24a4120-fea7-4048-bddb-66be19b378f0/npm-debug.log
npm ERR! not ok code 0
答案 0 :(得分:0)
这实际上是在uglify-js-brunch的v1.7.4中修复的