Skip to content

Commit 297f706

Browse files
feat(apple): App Hang Error Type (#12965)
Document which error / exception types the Cocoa SDK sets for app hangs V2.
1 parent 7e31485 commit 297f706

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

docs/platforms/apple/common/configuration/app-hangs.mdx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,8 @@ This feature is experimental and may have bugs.
141141

142142
As of version 8.39.0-beta.1, you can enable AppHangsV2, which is available on iOS and tvOS. The main difference is that AppHangsV2 differentiates between fully-blocking and non-fully-blocking app hangs, which you might choose to ignore, and since version 8.45.0 measures the duration of app hangs. A fully-blocking app hang is when the main thread is stuck completely, and the app can't render a single frame. A non-fully-blocking app hang is when the app appears stuck to the user, but can still render a few frames. Fully-blocking app hangs are more actionable because the stacktrace shows the exact blocking location on the main thread. Non-fully-blocking app hangs can have a stacktrace that doesn't highlight the exact blocking location, since the main thread isn't completely blocked.
143143

144+
The SDK sets the `exception.type` to `App Hang Fully Blocked` or `App Hang Non Fully Blocked`, so you can filter for App Hangs via `error.type` in Sentry.
145+
144146
To enable the feature:
145147

146148
```swift {tabTitle:Swift}
@@ -165,6 +167,7 @@ SentrySDK.start { options in
165167
166168
Starting with version 8.46.0, the SDK automatically detects and reports fatal app hangs. If the user or the [system watchdog](https://developer.apple.com/documentation/xcode/addressing-watchdog-terminations) terminates your app during an app hang, the SDK reports it as a fatal app hang on the next startup.
167169
170+
The SDK sets the `exception.type` to `Fatal App Hang Fully Blocked` or `Fatal App Hang Non Fully Blocked`, so you can filter for Fatal App Hangs via `error.type` in Sentry.
168171
169172
#### Non-Fully Blocking App Hangs
170173

0 commit comments

Comments
 (0)