-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Open
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/react-router
SDK Version
10.22.0
Framework Version
NA
Link to Sentry event
No response
Reproduction Example/SDK Setup
No response
Steps to Reproduce
Exact steps to reproduce are currently unclear
Expected Result
No errors sent by the SDK
Actual Result
Error as seen in Sentry:
URIError: URI malformed
at decodeURI (<anonymous>)
at ? (/var/task/node_modules/.pnpm/@sentry+core@10.22.0/node_modules/@sentry/core/build/esm/utils/node-stack-trace.js:99:30)
at ? (/var/task/node_modules/.pnpm/@sentry+core@10.22.0/node_modules/@sentry/core/build/esm/utils/stacktrace.js:42:23)
at parseStackFrames (/var/task/node_modules/.pnpm/@sentry+core@10.22.0/node_modules/@sentry/core/build/esm/utils/eventbuilder.js:10:10)
at exceptionFromError (/var/task/node_modules/.pnpm/@sentry+core@10.22.0/node_modules/@sentry/core/build/esm/utils/eventbuilder.js:22:18)
at eventFromUnknownInput (/var/task/node_modules/.pnpm/@sentry+core@10.22.0/node_modules/@sentry/core/build/esm/utils/eventbuilder.js:138:16)
at NodeClient.eventFromException (/var/task/node_modules/.pnpm/@sentry+core@10.22.0/node_modules/@sentry/core/build/esm/server-runtime-client.js:33:19)
at NodeClient.captureException (/var/task/node_modules/.pnpm/@sentry+core@10.22.0/node_modules/@sentry/core/build/esm/client.js:222:12)
at NodeClient.captureException (/var/task/node_modules/.pnpm/@sentry+core@10.22.0/node_modules/@sentry/core/build/esm/server-runtime-client.js:57:18)
at Scope.captureException (/var/task/node_modules/.pnpm/@sentry+core@10.22.0/node_modules/@sentry/core/build/esm/scope.js:504:18)
The stack trace points to this line:
return{
filename: filename ? decodeURI(filename) : undefined,
...
The exact cause of the error is unclear, but as pointed out by the affected user, a try/catch is used in another section as the decodeURI function can fail:
try {
newUrl = decodeURI(url);
} catch {
//Sometimes this breaks
}
A possible solution is to wrap it in a try/catch block.
Additional Context
No response
Priority
React with 👍 to help prioritize this issue. Please use comments to provide useful context, avoiding +1 or me too, to help us triage it.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Projects
Status
Waiting for: Product Owner