kotlinx.coroutines
kotlinx.coroutines copied to clipboard
Library support for Kotlin coroutines
**What do we have now?** The following deadlocks because nested `runBlocking` tries to process tasks from the outer `runBlocking`, and one of the tasks actually depends on the completion of...
https://teamcity.jetbrains.com/buildConfiguration/KotlinTools_KotlinxCoroutines_Build/4416699?hideProblemsFromDependencies=false&hideTestsFromDependencies=false&expandBuildChangesSection=true&logFilter=debug&logView=linear&showLog=4416699_23722__expandAll
**Describe the bug** In Kotlin/JS, when resuming the main coroutine exceptionally, the exception is thrown is the resuming coroutine (even if it's in a different scope) and it's not propagated...
``` java.lang.AssertionError: Expected pool threads to be in interval 0..9, but has 10 at org.junit.Assert.fail(Assert.java:89) at kotlin.test.junit.JUnitAsserter.fail(JUnitSupport.kt:56) at kotlin.test.Asserter$DefaultImpls.assertTrue(Assertions.kt:652) at kotlin.test.junit.JUnitAsserter.assertTrue(JUnitSupport.kt:30) at kotlin.test.Asserter$DefaultImpls.assertTrue(Assertions.kt:662) at kotlin.test.junit.JUnitAsserter.assertTrue(JUnitSupport.kt:30) at kotlin.test.AssertionsKt__AssertionsKt.assertTrue(Assertions.kt:44) at kotlin.test.AssertionsKt.assertTrue(Unknown Source)...
In general, we received mostly positive feedback about the API shape, and there is no reason to keep it experimental any further. Few things to address during stabilization: * Ensure...
I write this placeholder to consider the integration with JVM Virtual Thread implemented in project [LOOM](https://wiki.openjdk.org/display/loom/Main) (currently experimental on JVM 19 and 20). I made a simple [demo project](https://github.com/fvasco/game-of-life-csp-fusco) (see...
This PR fixes a typo in the `coroutine-context-and-dispatchers.md`.
Due to the prompt cancellation guarantee changes that landed in Coroutines 1.4, Channels cannot be used as mechanism that guarantees delivery _and_ acknowledges successful processing between producer and consumer in...
### Problem statement A **very** common pain point when using our testing framework is that `StateFlow` conflates values emitted in quick succession. Example (all examples are written without Turbine, DI...
## Problem statement, the short version We receive a lot of questions about using the test module, the answer to which is to avoid using `advanceUntilIdle`/`advanceTimeBy`. `advanceTimeBy`, `advanceUntilIdle`, and `runCurrent`...