question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Crash after upgrade from 1.3.0 to 1.3.1

See original GitHub issue

Since I updated to coroutines 1.3.1 on Android projects it started to crash on all existing 3rd libraries that using coroutines too.

It is just minor bugfix version I would not expect backward incompatibility on such release.

But there is this small unimportant note:

Note: Kotlin/Native artifacts are now published with Gradle metadata format version 1.0, so you will need Gradle version 5.3 or later to use this version of kotlinx.coroutines in your Kotlin/Native project.

Can this be a reason?

My project is using Gradle 5.6.2, but the library is using an older version than 5.3

    java.lang.IllegalStateException: Module with the Main dispatcher is missing. Add dependency providing the Main dispatcher, e.g. 'kotlinx-coroutines-android'
        at kotlinx.coroutines.internal.MissingMainCoroutineDispatcher.missing(MainDispatchers.kt:90)
        at kotlinx.coroutines.internal.MissingMainCoroutineDispatcher.isDispatchNeeded(MainDispatchers.kt:71)
        at kotlinx.coroutines.DispatchedKt.resumeCancellable(Dispatched.kt:420)
        at kotlinx.coroutines.intrinsics.CancellableKt.startCoroutineCancellable(Cancellable.kt:26)
        at kotlinx.coroutines.CoroutineStart.invoke(CoroutineStart.kt:109)
        at kotlinx.coroutines.AbstractCoroutine.start(AbstractCoroutine.kt:154)
        at kotlinx.coroutines.BuildersKt__Builders_commonKt.launch(Builders.common.kt:54)
        at kotlinx.coroutines.BuildersKt.launch(Unknown Source:1)
        at kotlinx.coroutines.BuildersKt__Builders_commonKt.launch$default(Builders.common.kt:47)
        at kotlinx.coroutines.BuildersKt.launch$default(Unknown Source:1)

I have both dependencies

    implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core:1.3.1'
    implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:1.3.1'

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:6
  • Comments:23 (6 by maintainers)

github_iconTop GitHub Comments

4reactions
mhernand40commented, Sep 30, 2019

FWIW, my team was also running into this crash when we upgraded from 1.3.1 to 1.3.2. The workaround we’ve used was to run ./gradlew clean followed by the corresponding install task using the --no-build-cache argument.

3reactions
svenjacobscommented, Sep 23, 2019

Having the same problem here after upgrading to 1.3.1. The error seems to happen randomly, not every time. Downgrading to 1.3.0 fixes it. R8 config was not changed between these two versions.

Update: Also happening for debug builds without R8!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Luminar Neo 1.3.1 crashing while starting after update
Luminar Neo 1.3.1 crashing while starting after update. ... Could you please specif if the update 1.3.0 is also crashing?
Read more >
If Tinfoil crashes your game on 14.1.0 + Atmo 1.3.1 here's the fix
I'm on emummc) and trying to launch into homebrew after that would crash atmosphere and ask to reboot. I've tried deleting atmosphere and ......
Read more >
Monitor crash after upgrade to RHEL 7.1 CEPH-1.3.0
1 ceph 1.3.0, but after upgrade monitor is not able to start but crashing. 7. Now the cluster is in mixed mode MON1----->...
Read more >
App starts to crash after upgrade to SDK 31 Android
In your first stack trace it is indicating that the work manager is crashing while trying to create a PendingIntent :
Read more >
Just updated my switch to 14.1.0 and getting a crash when I try ...
Atmosphere and Hekate are both updated to the newest versions (1.3.1 for atmosphere and hekate v5.7.2). I also updated my signature patches from ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found