Repository navigation
Closed
Description
Is there an existing issue for this?
- I have checked for existing issues https://github.com/getsentry/sentry-javascript/issues
- I have reviewed the documentation https://docs.sentry.io/
- I am using the latest SDK release https://github.com/getsentry/sentry-javascript/releases
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/browser
SDK Version
7.108
Framework Version
React Router v5.3.4
Link to Sentry event
No response
SDK Setup
Sentry.init({
dsn: "...",
release: "app@" + appVersion,
integrations: [
Sentry.reactRouterV5BrowserTracingIntegration({
history,
enableInp: true,
shouldCreateSpanForRequest: (url) => {
return !url.match(/(\/cookie-jar\/|\/comscore.json)/);
},
}),
],
environment,
allowUrls,
denyUrls,
ignoreErrors,
tracesSampleRate,
beforeSend: beforeSend(beforeSendFilter),
});
// Route.js
import { Route } from "react-router-dom";
import { withSentryRouting } from "@sentry/react";
export default withSentryRouting(Route);
---
// App.js
const history = createBrowserHistory();
function App() {
// ...
const renderRoutes = routes.map(({ path, component, exact }, index) => {
const Component = component;
return (
<Route
key={index}
exact={exact}
path={path}
render={(renderProps) => {
// some logic here
return <Component {...renderProps} />;
}}
/>
);
});
// ...
return (
<Router history={history}>
{/* ... */}
<Switch>{renderRoutes}</Switch>
{/* ... */}
</Router>
);
}
Steps to Reproduce
Update SDK and parametrization suddenly changed from catching /:section*/:title-:contentId(\d.\d+)
to what looks like might be the default sdk's parametrization attempt.
Expected Result
Custom parametrization logic still being applied
Actual Result
Available in internal customer case.
Looks like the default sdk parametrization is being used
https://www.notion.so/sentry/Broken-parametrization-in-updated-JS-sdk-d8150eb03fbc4a409ca931761cc2e786
Metadata
Metadata
Assignees
Labels
No labels
Projects
- StatusShow more project fieldsNo status
Activity
mydea commentedon May 7, 2024
Hey,
thanks for writing in. We probably have to backport #11855, forgot about that - we'll look into it!
fix(react/v7): Fix react router v4/v5 span names (#11940)
mydea commentedon May 15, 2024
So we've released a new v7 version with this fix, as well as also having a stable v8.0.0 version out where that should be fixed. I'll close this issue, if you still encounter this on the latest version (of either v7 or v8) please feel free to reopen!