Hello there, I have a problem with resolution of c...
# coroutines
r
Hello there, I have a problem with resolution of correct version of coroutines during build. My project is KMM project. It uses a kmm library which uses internally coroutines. That library use version
1.5.1-native-mt
and forces it by
strictly
config. I use this library as
api
gradle dependency in
shared/commonMain
module. The problem is that I also use some dependencies in Android app that also use coroutines but not the
1.5.1-native-mt
branch.
m
What version shows as resolved in
./gradlew :app:dependencies
?
If it's
1.5.1-native-mt
you should be good to go. It's kinda of superset of
1.5.1
r
Copy code
Execution failed for task ':app:checkDevDebugAarMetadata'.
> Could not resolve all files for configuration ':app:devDebugRuntimeClasspath'.
   > Could not resolve org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.0.
     Required by:
         project :app > androidx.compose.ui:ui:1.0.3
         project :app > androidx.compose.animation:animation:1.0.3 > androidx.compose.animation:animation-core:1.0.3
m
There's always the big hammer option:
Copy code
allprojects {
    configurations {
        all {
            resolutionStrategy {
                force("org.jetbrains.kotlinx:kotlinx-coroutines-core:x.y.z-native-mt")
            }
        }
    }
}
🔨 1
❤️ 2
r
Thx, you nailed it 😄
😂 1
👍 1