You are currently viewing A question about coroutine jobs

A question about coroutine jobs

Yesterday, I posted this question on StackOverflow:
https://stackoverflow.com/questions/66920617/kotlin-why-isnt-job-invokeoncompletion-block-running-on-main-thread

I was already able to solve the issue with the exception described in the question by launching yet another coroutine within my job completion callback. However, I’m still curious why the job.invokeOnCompletion() block of code is not running on the main thread? It confuses me a bit.

submitted by /u/TCW_Jocki
[link] [comments]