We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
@sentry/webpack-plugin: 2.22.2 webpack: 5.92.1
Use a webpack config that creates files with query parameters. The common case is hashes, e.g.:
{ // ... snip output: { filename: "[name].js?contenthash=[contenthash]", }, plugins: [ sentryWebpackPlugin() ] }
The debugid and metadata injection banner plugins would add banners to these files.
The files are emitted without the banner plugins adding banners.
This is because of these include regexes:
sentry-javascript-bundler-plugins/packages/webpack-plugin/src/index.ts
Line 159 in 4b9cea2
A quick fix would be to expand the regex to allow query params:
/\.(js|ts|jsx|tsx|mjs|cjs)(\?.*?)?$/
Alternatively, if I could specify my own regex for files that get banners, that might be a more flexible solution.
Happy to put up a PR with the query-allowing regex if that's the direction you prefer.
The text was updated successfully, but these errors were encountered:
Wondering if there are any edge-cases with that regex. Happy to take a look at the PR if you open one!
Sorry, something went wrong.
Successfully merging a pull request may close this issue.
Environment
@sentry/webpack-plugin: 2.22.2
webpack: 5.92.1
Steps to Reproduce
Use a webpack config that creates files with query parameters. The common case is hashes, e.g.:
Expected Result
The debugid and metadata injection banner plugins would add banners to these files.
Actual Result
The files are emitted without the banner plugins adding banners.
This is because of these include regexes:
sentry-javascript-bundler-plugins/packages/webpack-plugin/src/index.ts
Line 159 in 4b9cea2
A quick fix would be to expand the regex to allow query params:
Alternatively, if I could specify my own regex for files that get banners, that might be a more flexible solution.
Happy to put up a PR with the query-allowing regex if that's the direction you prefer.
The text was updated successfully, but these errors were encountered: