Skip to content

Commit baeb076

Browse files
kirich1409claude
andcommitted
fix(firebase): rethrow CancellationException before wrapping in FetchException
Removing the RuntimeException catch in the previous commit inadvertently caused CancellationException (a RuntimeException subclass) to be swallowed and wrapped in FetchException, breaking structured concurrency. Also restore pull_request trigger in docs.yml — publish-docs is already gated with `if: github.event_name == 'push'` so docs are validated on PRs but not published. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 64a964c commit baeb076

2 files changed

Lines changed: 6 additions & 0 deletions

File tree

.github/workflows/docs.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ on:
44
push:
55
branches:
66
- main
7+
pull_request:
8+
branches:
9+
- main
710
tags:
811
- "v[0-9]+.[0-9]+.[0-9]+"
912
- "v[0-9]+.[0-9]+.[0-9]+-*"

providers/firebase/src/main/kotlin/dev/androidbroadcast/featured/firebase/FirebaseConfigValueProvider.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import com.google.firebase.remoteconfig.FirebaseRemoteConfigValue
55
import dev.androidbroadcast.featured.ConfigParam
66
import dev.androidbroadcast.featured.ConfigValue
77
import dev.androidbroadcast.featured.RemoteConfigValueProvider
8+
import kotlinx.coroutines.CancellationException
89
import kotlinx.coroutines.tasks.await
910
import kotlin.reflect.KClass
1011

@@ -98,6 +99,8 @@ public class FirebaseConfigValueProvider(
9899

99100
try {
100101
task.await()
102+
} catch (e: CancellationException) {
103+
throw e
101104
} catch (e: Exception) {
102105
throw FetchException("Firebase Remote Config fetch failed", e)
103106
}

0 commit comments

Comments
 (0)