launch

fun launch(scope: ERROR CLASS: Symbol not found for CoroutineScope, timeoutMs: Long = 0, block: suspend ERROR CLASS: Symbol not found for CoroutineScope.() -> Unit)(source)

Cancels the previous job (if any) and launches a new one in the given scope. The new job uses handledLaunch to ensure exceptions are reported.

Parameters

timeoutMs

Optional timeout in milliseconds. If > 0, the block is wrapped in withTimeout so that indefinitely-suspended coroutines (e.g. blocked DataStore reads) throw TimeoutCancellationException instead of hanging silently.