feat: Allow accessing event exception values in before_send handler#415
feat: Allow accessing event exception values in before_send handler#415
before_send handler#415Conversation
|
before_send handlerbefore_send handler
android_lib/src/main/java/io/sentry/godotplugin/SentryAndroidGodotPlugin.kt
Show resolved
Hide resolved
|
Would it be technically possible to have exceptions exposed as dictionary variants, for example? Would it allow replacing any field, not just the exception value, at the cost of losing strong typing? |
@jpnurmi Technically speaking, yes. However, this would only be a good fit with Native. SDKs like Android and Cocoa have strong-typed abstractions, making implementation much more complicated. We would have to interpret the dictionary ourselves and implement translation to Exception, Stacktrace, and Frame types (stacktrace is an attribute of exception), which would require much more effort to implement. And we also lose strong typing. Additionally, if we don't have support for, let's say, some specific field in a Frame or Stacktrace, it wouldn't be clear if that is the case from the interface. |
This PR allows accessing and changing event exception values in the
before_sendhandler. This is important for processing error events because, in the current version, there is no way to access the error message.before_sendhandler #412