angular-cli: ProgressPlugin breaks with webpack 4.25.* due to incorrect option colors
Bug Report or Feature Request (mark with an x)
- [x ] bug report -> please search issues before submitting
- [ ] feature request
Command (mark with an x)
- [ ] new
- [*] build
- [*] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [ ] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc
Versions
Repro steps
npm install npm run build / serve
The log given by the failure
Progress Plugin Invalid Options
options[‘colors’] is an invalid additional property options should pass “instanceof” keyword validation options should match exactly one schema in oneOf
ValidationError: Progress Plugin Invalid Options
options[‘colors’] is an invalid additional property options should pass “instanceof” keyword validation options should match exactly one schema in oneOf
Desired functionality
In common.ts#L147 the ProgressPlugin is called with parameter colors. This does not meet the schema which is validated ProgressPlugin.js#L90
Mention any other details that might be useful
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Reactions: 26
- Comments: 39 (3 by maintainers)
Commits related to this issue
- fix(@angular-devkit/build-angular): allow only patch version of webpack Fix #12866 — committed to filipesilva/angular-cli by filipesilva 6 years ago
- fix(@angular-devkit/build-angular): allow only patch version of webpack Fix #12866 — committed to filipesilva/angular-cli by filipesilva 6 years ago
- fix(@angular-devkit/build-angular): allow only patch version of webpack Fix #12866 — committed to filipesilva/angular-cli by filipesilva 6 years ago
- fix(@angular-devkit/build-angular): allow only patch version of webpack (#12870) Fix #12866 — committed to angular/angular-cli by filipesilva 6 years ago
- Updated to Angular 7 in order to avoid the following error: options['colors'] is an invalid additional property. Solution: https://github.com/angular/angular-cli/issues/12866 — committed to josealonso/angular-http by josealonso 6 years ago
Can be fixed temporarily by adding this line to package.json
then
npm installI had the same issue on Ubuntu 18.10, Node 10.8.0, NPM 6.2.0 and Angular CLI 6.2.6.
Fixed it with removing colors option on this file: /node_modules/@angular-devkit/build-angular/src/angular-cli-files/models/webpack-configs/common.js on Line: 123
Changed this: extraPlugins.push(new ProgressPlugin({ profile: buildOptions.verbose, colors: true })); to: extraPlugins.push(new ProgressPlugin({ profile: buildOptions.verbose }));
Hope this help. Cheers.
ng update --alldid the work!update from
to
Worked for me! Thanks. Deleted node_modules, then ran
npm cache clean --force && npm install && npm install --open --prodmake ng update
Another workaround is
ng serve --progress=falseuntil you can update angular-cli@angular/cli@6.2.7alone didn’t make it, had to upgrade one more:Its works! Thanks!
Having same issue while fresh npm install.
I am facing same issue. None of the above solutions working for me . Any other suggestions ?
I have the same issue but only in Ubuntu 16.04. On Windows 10 it works just fine. Using Node 8.x
Having the same issue when a making fresh project. Edit: On a Windows 10 laptop
Repro steps
ng new [project-name] npm install && ng serve --open --prod
Expected result
Should open new window with fresh project opened
Result
Version