Skip to content

Commit 2230ca7

Browse files
Lms24lobsterkatie
andauthored
ref(develop): Clarify synthetic flag in exception mechanism (#12125)
Clarifies/expands on the impact and applicability of the `synthetic` flag in the exception `mechanism`: - adds impact on issue grouping - adds another concrete use case when to set the flag --------- Co-authored-by: Katie Byers <[email protected]>
1 parent 5b2973a commit 2230ca7

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

develop-docs/sdk/data-model/event-payloads/exception.mdx

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -79,14 +79,18 @@ from the operating system or runtime APIs, as well as mechanism-specific values.
7979

8080
`synthetic`
8181

82-
: An optional flag indicating that this error is synthetic. Synthetic errors
83-
are errors that carry little meaning by themselves. This may be because they
84-
are created at a central place (like a crash handler), and are all
85-
called the same: `Error`, `Segfault` etc. When the flag is set, Sentry will then
86-
try to use other information (top in-app frame function) rather than exception
87-
type and value in the UI for the primary event display. This flag should be set
88-
for all "segfaults" for instance as every single error group would look very
89-
similar otherwise.
82+
: An optional flag indicating that this error is synthetic. Synthetic errors are errors that
83+
carry little meaning by themselves. This may be because they are created at a central
84+
place (like a crash handler), and are all called the same: `Error`, `Segfault` etc.
85+
When the flag is set, Sentry will then try to use other information (top in-app frame
86+
function) rather than the exception type and value in the UI for the primary event display.
87+
Furthermore, if this flag is set, Sentry will ignore the exception `type` when grouping the
88+
exception into issues.
89+
: This flag should be set for all "segfaults" for instance as every single error group would
90+
look very similar otherwise. Also, errors the SDK creates to add a stack trace to events
91+
that don't have one themselves should be marked as `synthetic` (This happens, for example,
92+
when users set `attachStackTrace: true` and capture a string message via `captureException`
93+
or `captureMessage`.)
9094

9195
`exception_id`
9296

0 commit comments

Comments
 (0)