Compile errors after updating to WorkManager 1.0.0-alpha09
As per the WorkManager 1.0.0-alpha09 release notes:
Known Issue
If you run into the following issue: "More than one file was found with OS independent path 'META-INF/proguard/androidx-annotations.pro'", please put the following in your gradle file as a temporary workaround while we fix the issue in alpha10:
android {
packagingOptions {
exclude 'META-INF/proguard/androidx-annotations.pro'
}
}
Edit: Your additional errors are caused by this issue:
It is done on purpose: https://groups.google.com/forum/#!topic/guava-announce/Km82fZG68Sw
New release of guava will be ready soon, that will resolve that issue automatically.
For now you can exclude
"com.google.guava:listenablefuture"
in your gradle file:
implementation("android.arch.work:work-runtime:1.0.0-alpha09") {
exclude group: 'com.google.guava', module: 'listenablefuture'
}
Everything works fine if you have a project with Guava v27 and the newest version of WorkManager. I just tried it out and it fixes my project.
This builds just fine:
dependencies {
implementation 'android.arch.work:work-runtime:1.0.0-beta01'
implementation 'com.google.guava:guava:27.0.1-android'
}