https://kotlinlang.org logo
Title
n

nimtiazm

10/04/2018, 5:13 AM
I created a jvm project and used coroutines version 0.30.1-eap13 with kotlin 1.3.0-rc-146. When I spin up my main method a basic coroutine, i get the following exception: Exception in thread “main” java.lang.NoClassDefFoundError: android/os/Looper at kotlinx.coroutines.android.HandlerDispatcherKt.<clinit>(HandlerDispatcher.kt:60)
h

Hamza

10/04/2018, 5:15 AM
may we see your build file?
n

nimtiazm

10/04/2018, 5:15 AM
<dependency> <groupId>org.jetbrains.kotlin</groupId> <artifactId>kotlin-stdlib</artifactId> <version>${kotlin.version}</version> </dependency> <dependency> <groupId>org.jetbrains.kotlin</groupId> <artifactId>kotlin-test-junit</artifactId> <version>${kotlin.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.jetbrains.kotlinx</groupId> <artifactId>kotlinx-coroutines-android</artifactId> <version>0.30.1-eap13</version> </dependency>
that’s all i have that’s kotlin specific
h

Hamza

10/04/2018, 5:16 AM
try running
mvn clean verify
n

nimtiazm

10/04/2018, 5:16 AM
it ran successfully
no i’m rebuilding
i ran the jar again and got the same exception
h

Hamza

10/04/2018, 5:17 AM
have you tried a stable version of coroutines and seen if it works?
n

nimtiazm

10/04/2018, 5:18 AM
with 1.3 non-experimental i don’t have a choice to use stable version right?
1.3 itself is in rc
h

Hamza

10/04/2018, 5:18 AM
try using 0.21
n

nimtiazm

10/04/2018, 5:18 AM
last time i used 0.26-eap13, it used to work
h

Hamza

10/04/2018, 5:19 AM
hmm, that is quite odd
n

nimtiazm

10/04/2018, 5:19 AM
indeed
i tried to old version but it’s not compatible with 1.3 rc 146
d

Dico

10/04/2018, 9:09 AM
You're depending on
kotlinx-coroutines-android