micromata/Baumeister

npm scripts throwing errors

mischah opened this issue · 4 comments

The build process fails after a fresh install with the following error:

TypeError: Cannot read property 'properties' of undefined

It’s caused by a bug introduced in webpack 4.20.0 (See webpack/webpack#8082)

Current workaround

Install and use webpack 4.19.0:

npm i -D webpack@4.19.0

Sorry for the inconvenience.

Complete error log in the Terminal:

$ npm run start

> testchen@0.0.0 start /Users/mkuehnel/temp/testchen
> npm-run-all clean:dev handlebars --parallel handlebars:watch webpack:server eslint:watch stylelint:watch --silent

✔  Finished Handlebars build after 167 ms

/Users/mkuehnel/temp/testchen/node_modules/webpack-cli/bin/config-yargs.js:89
				describe: optionsSchema.definitions.output.properties.path.description,
				                                           ^

TypeError: Cannot read property 'properties' of undefined
    at module.exports (/Users/mkuehnel/temp/testchen/node_modules/webpack-cli/bin/config-yargs.js:89:48)
    at Object.<anonymous> (/Users/mkuehnel/temp/testchen/node_modules/webpack-dev-server/bin/webpack-dev-server.js:84:40)
    at Module._compile (module.js:635:30)
    at Object.Module._extensions..js (module.js:646:10)
    at Module.load (module.js:554:32)
    at tryModuleLoad (module.js:497:12)
    at Function.Module._load (module.js:489:3)
    at Function.Module.runMain (module.js:676:10)
    at startup (bootstrap_node.js:187:16)
    at bootstrap_node.js:608:3
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! testchen@0.0.0 start: `npm-run-all clean:dev handlebars --parallel handlebars:watch webpack:server eslint:watch stylelint:watch --silent`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the testchen@0.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/mkuehnel/.npm/_logs/2018-10-21T21_10_58_615Z-debug.log

I have the same problem. I can run "npm run start", it works , but when I run "npm run build",
it shows the error:

$ npm run build

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! webapp@0.0.0 build: npm-run-all security test handlebars clean webpack --silent
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the webapp@0.0.0 build 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/jwang/.npm/_logs/2018-11-29T14_24_34_143Z-debug.log

in package.json:

"webpack": "4.19.0",
"webpack-assets-manifest": "^3.0.0",
"webpack-bundle-analyzer": "^2.13.1",
"webpack-cli": "^3.1.2",
"webpack-dev-server": "^3.1.5"

Upgrading webpack-cli to the latest will solve the issue

Thanks @ematipico 💯

The current master branch builds correctly with Node 6, 8, 10 and 11 and a proper release will follow within this week.