From af089241b9e3edd06e35f47ed31377b289508574 Mon Sep 17 00:00:00 2001 From: lcian Date: Fri, 11 Apr 2025 14:42:18 +0200 Subject: [PATCH] Add `handled=true` to `SentryCoroutineExceptionHandler` --- .../java/io/sentry/kotlin/SentryCoroutineExceptionHandler.kt | 1 + 1 file changed, 1 insertion(+) diff --git a/sentry-kotlin-extensions/src/main/java/io/sentry/kotlin/SentryCoroutineExceptionHandler.kt b/sentry-kotlin-extensions/src/main/java/io/sentry/kotlin/SentryCoroutineExceptionHandler.kt index 9fc4a23d2e1..076a0c69aec 100644 --- a/sentry-kotlin-extensions/src/main/java/io/sentry/kotlin/SentryCoroutineExceptionHandler.kt +++ b/sentry-kotlin-extensions/src/main/java/io/sentry/kotlin/SentryCoroutineExceptionHandler.kt @@ -21,6 +21,7 @@ public open class SentryCoroutineExceptionHandler(private val scopes: IScopes = override fun handleException(context: CoroutineContext, exception: Throwable) { val mechanism = Mechanism().apply { type = "CoroutineExceptionHandler" + isHandled = true } // the current thread is not necessarily the one that threw the exception val error = ExceptionMechanismException(mechanism, exception, Thread.currentThread())