Reputation: 19190
I wanted to test latest version of jetpack compose 1.3.0-alpha02 (Changelog). So I created a new project and updated the version to 1.3.0-alpha02
But when running it, I get this error like something's not found:
Execution failed for task ':app:compileDebugKotlin'.
> Could not resolve all files for configuration ':app:kotlin-extension'.
> Could not find androidx.compose.compiler:compiler:1.3.0-alpha02.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/androidx/compose/compiler/compiler/1.3.0-alpha02/compiler-1.3.0-alpha02.pom
- https://repo.maven.apache.org/maven2/androidx/compose/compiler/compiler/1.3.0-alpha02/compiler-1.3.0-alpha02.pom
Required by:
project :app
What is the reason? I did nothing special. Just updated the version
Upvotes: 3
Views: 2719
Reputation: 19190
There's something you missed to look at
Although when you create a Template compose project using Android studio, it assumes that both compose libs
and compose-compiler
are the same version, but for 1.3.0-alpha01
it's different
From Release note:
You should see that compose-compiler
version is 1.3.0-rc02
So go and update it:
// app/build.gradle
composeOptions {
// kotlinCompilerExtensionVersion compose_version // Change this
kotlinCompilerExtensionVersion "1.3.0-rc02" // to this
}
And then retry syncing
Generally, the version of Compose libraries might be different than compose-compiler
, so when adding them, make sure you add the proper version.
Upvotes: 5