Skip to content

Conversation

@snitin315
Copy link
Member

What kind of change does this PR introduce?
maybe fix

Did you add tests for your changes?
Yes
If relevant, did you update the documentation?
No
Summary
Fixes #1794

show a warning if bail and watch are used together with either config or as cli args.

Does this PR introduce a breaking change?
No

Other information
No

@snitin315 snitin315 requested a review from a team as a code owner September 17, 2020 08:48
expect(stderr).toContain(`You are using "bail" with "watch". "bail" will still exit webpack when the first error is found.`);
expect(stdout).toBeTruthy();
});
});
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add tests where bail: false and watch: true/watch: false and bail: true and check there is not warnings/errors?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added

evenstensberg
evenstensberg previously approved these changes Sep 20, 2020
rishabh3112
rishabh3112 previously approved these changes Sep 20, 2020
Copy link
Member

@rishabh3112 rishabh3112 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a small suggestion.
Rest looks good to me.

@@ -0,0 +1,7 @@
const logger = require('../logger');

module.exports = (compiler) => {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Assign this to variable and then assign it to module.exports.
Add a comment about function(or file) as well.

@webpack-bot
Copy link

@jamesgeorge007 Thanks for your update.

I labeled the Pull Request so reviewers will review it again.

@evenstensberg Please review the new changes.

@snitin315 snitin315 merged commit 6140b24 into next Sep 21, 2020
@snitin315 snitin315 deleted the fix/bail-watch-warn branch September 21, 2020 13:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bail = true should not kill watch mode on ModuleNotFound error

7 participants