From 665f60e4af7e621471564a651e185e6401ff28ca Mon Sep 17 00:00:00 2001 From: Noah Allen Date: Mon, 23 May 2022 11:30:08 -0700 Subject: [PATCH] Never fail webpack build from sentry (#63930) --- client/webpack.config.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/client/webpack.config.js b/client/webpack.config.js index e42f76b5a01f9..0f365c8445854 100644 --- a/client/webpack.config.js +++ b/client/webpack.config.js @@ -386,6 +386,10 @@ const webpackConfig = { release: `calypso_${ process.env.COMMIT_SHA }`, include: filePaths.path, urlPrefix: `~${ filePaths.publicPath }`, + errorHandler: ( err, invokeErr, compilation ) => { + // Sentry should _never_ fail the webpack build, so only emit warnings here: + compilation.warnings.push( 'Sentry CLI Plugin: ' + err.message ); + }, } ), ].filter( Boolean ), externals: [ 'keytar' ],