bail not work

Bug report

What is the current behavior?
webpack –config webpack.config –bail when error occured webpack don’t exit

and i debuged the case and found maybe is here a bug in NormalModule?

// if we have an error mark module as failed and exit if (err) { this.markModuleAsErrored(err); this._initBuildHash(compilation); return callback(); }

should return callback to be return callback(err) then the bail can work

If the current behavior is a bug, please provide the steps to reproduce.

use mini-css-extract-plugin loader but not use mini-css-extract-plugin plugin

What is the expected behavior?

bail parameter works as what it meaned

Other relevant information:
webpack version: lastest
Node.js version: v8.11.3
Operating System: window7
Additional tools:

Author: Fantashit

1 thought on “bail not work

Comments are closed.