diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 61ee428b..d056ad00 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -121,7 +121,9 @@ jobs: fi log="$(mktemp)" status=0 - ./gradlew $TASKS --stacktrace --no-daemon 2>&1 | tee "$log" \ + # iosSkip: Nucleus's native-image resource task pulls in the iOS tasks of the app's modules, + # and the Kotlin plugin refuses to create those on a Linux arm64 host. + ./gradlew $TASKS -PiosSkip=true --stacktrace --no-daemon 2>&1 | tee "$log" \ || status="${PIPESTATUS[0]}" if [ "$status" -eq 0 ]; then exit 0 diff --git a/wrayth/src/jvmTest/kotlin/WraythStreamRoutingTests.kt b/wrayth/src/jvmTest/kotlin/WraythStreamRoutingTests.kt index d050d4b9..8a7328a5 100644 --- a/wrayth/src/jvmTest/kotlin/WraythStreamRoutingTests.kt +++ b/wrayth/src/jvmTest/kotlin/WraythStreamRoutingTests.kt @@ -159,7 +159,9 @@ class WraythStreamRoutingTests { val main = mutableListOf() val streams = mutableListOf() val mainSubscribed = CompletableDeferred() - scope.launch { + // Unconfined, so each collector takes a line inside the client's own send: nothing can + // still be buffered when the client disconnects, and scope.cancel below loses nothing. + scope.launch(Dispatchers.Unconfined) { client.eventFlow.onSubscription { mainSubscribed.complete(Unit) }.collect { event -> if (event is ClientTextEvent) { synchronized(main) { main += event } @@ -168,7 +170,7 @@ class WraythStreamRoutingTests { } // Undispatched, so each is subscribed before the client connects. for (stream in watched) { - scope.launch(start = CoroutineStart.UNDISPATCHED) { + scope.launch(Dispatchers.Unconfined, start = CoroutineStart.UNDISPATCHED) { client.streamLines(stream).collect { event -> synchronized(streams) { streams += event } }