Open wcardosodev opened 7 hours ago
Hello and thanks for reaching out! How does your ErrorBoundary
component look like? It would be awesome if you could provide us with a minimal reproduction example so we can have a better look at it and are able to define the exact problem.
Is there an existing issue for this?
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/react
SDK Version
7.119.1
Framework Version
18.2.0
Link to Sentry event
https://statsbomb.sentry.io/issues/5999056924/?environment=development&project=4506507098062848&query=is%3Aunresolved%20issue.priority%3A%5Bhigh%2C%20medium%5D&referrer=issue-stream&statsPeriod=1h&stream_index=0
Reproduction Example/SDK Setup
Steps to Reproduce
We are using jotai and if we make a query using
atomWithQuery
oratomWithSuspenseQuery
and the response is bad, we throw an error i.e:The problem here is that errors thrown from the fetch don't get marked as
handled
by sentry, even though the component they get called from are wrapped with anErrorBoundary
with afallback
like:Instead these get marked as unhandled, whereas if you did something similar but threw the error just inside the component (rather than in the fetch itself) it would be marked as handled i.e
Which you can see here being marked as handled: https://statsbomb.sentry.io/issues/6011758573/?environment=development&project=4506507098062848&query=is%3Aunresolved%20issue.priority%3A%5Bhigh%2C%20medium%5D&referrer=issue-stream&statsPeriod=1h&stream_index=1
Expected Result
Expected behaviour is that the error gets marked as handled as it's happening within a component being wrapped by an ErrorBoundary.
Actual Result
The error is not being marked as handled