Overwriting of `extra` when capturing an exception
zeorin opened this issue · comments
I've implemented this library in my Redux middleware and it's generally working quite well.
However, I've also set up some React Error Boundaries that report to my Sentry.io instance, as per https://blog.sentry.io/2017/09/28/react-16-error-boundaries.
When I manually trigger Raven.captureException
in my Error Boundary component as per the blog post, an exception is logged on Sentry, but without the componentStack
part being in the extra
part of the data that is being sent to Sentry. The state
is there as expected.
If I inspect the network request that's being made to Sentry, it's the same. The state
is there, but the property that was added to extra
in the captureException
call has been discarded.
Additionally, if the above is fixed, it'd be awesome if one could still overwrite the state
that is automatically added by manually specified state in extra
. This is useful when e.g. a promise throws an error after some time and we'd like to send a report with the state at the time the promise was created rather than the state at the time that it threw an error.
Would something like this work? #59
That looks great! Thank you!
Published in 1.3.0