sentry-javascript-bundler-plugins
sentry-javascript-bundler-plugins copied to clipboard
Sourcemap file paths in Sentry are different with its in console of online website.
Environment
rsbuild + @sentry/webpack-plugin + React + Self-host sentry 25.1.0.dev0
Steps to Reproduce
- Setup the Sentry init in
main.tsx
Sentry.init({
dsn: import.meta.env.SENTRY_DSN,
integrations: [
Sentry.browserTracingIntegration(),
Sentry.replayCanvasIntegration(),
Sentry.replayIntegration({
blockAllMedia: false,
...(import.meta.env.VITE_SENTRY_SENSITIVE === 'false' ? { maskAllInputs: false, maskAllText: false } : {}),
}),
],
release: import.meta.env.APP_VERSION,
dist: import.meta.env.APP_VERSION,
// Tracing
tracesSampleRate: 1.0, // Capture 100% of the transactions
// Set 'tracePropagationTargets' to control for which URLs distributed tracing should be enabled
tracePropagationTargets: [****],
// Session Replay
replaysSessionSampleRate: 0.1, // This sets the sample rate at 10%. You may want to change it to 100% while in development and then sample at a lower rate in production.
replaysOnErrorSampleRate: 1.0, // If you're not already sampling the entire session, change the sample rate to 100% when sampling sessions where errors occur.
});
- Setup the webpack plugin in rsbuild.config.ts
sentryWebpackPlugin({
org: 'sentry',
project: import.meta.env.VITE_SENTRY_PROJECT,
url: '***',
telemetry: false,
release: {
name: import.meta.env.APP_VERSION,
dist: import.meta.env.APP_VERSION,
},
authToken: '***'
}),
-
Deploy the front-end project to website.
-
I triggered an error and checked the console in browser. It can show the concrete file of source code. Such as
instanceList.tsx. -
Check the issue on sentry. The error stack trace is different with console. It seems like:
Is there something I didn't configure correctly?
Expected Result
I hope I can check the stack trace same with browser console.