You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The AndroidX Emoji library (as well as Room, and others) define a repackaged jar dependency by doing the following in their Gradle build script
dependencies {
repackage project(path: ':noto-emoji-compat', configuration: "parser")
// Wrap the noto-emoji-compat dependency in a FileCollection so that the Android Gradle plugin
// treats this as local jar and package it inside the aar.
api files(configurations.repackage)
api("androidx.core:core:1.1.0-rc01")
...
With downloadInBuck = true, this causes a failure after OkBuck runs with the following exception (since this target doesn't exist)
Unable to download: mvn:androidx.emoji:emoji:jar:1.0.0
Building: finished in 4.1 sec (100%) 268/779 jobs, 144 updated
Total time: 4.6 sec
Command failed with exit code -1.
When running <curl>.
When building rule //.okbuck/ext/androidx/emoji:emoji-1.0.0.jar__downloaded.
With downloadInBuck = false a different exception occurs when trying to symlink the downloaded jar to the existing aar
> Task :okbuck FAILED
Could not create symlink .okbuck/ext/androidx/emoji/emoji-1.0.0-sources.jar -> .gradle/caches/modules-2/files-2.1/androidx.emoji/emoji/1.0.0/5315d6ba250959ffc6b999879a48ea78c009b493/emoji-1.0.0-sources.jar
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':okbuck'.
> java.nio.file.FileAlreadyExistsException: .okbuck/ext/androidx/emoji/emoji-1.0.0-sources.jar
It appears that what is happening is that OkBuck in the dependency processing step is collecting both the AAR and the JAR from the artifact because they have the same name, then either trying to make a duplicate symlink or download a jar that doesn't exist
I did a bit of (brutish) exploration here NickFirmani@b8a5c06 to try and fix this, I don't think that this is quite the correct approach, but it does solve the problem, just preferring the AAR over the JAR if both exist.
The text was updated successfully, but these errors were encountered:
The AndroidX Emoji library (as well as Room, and others) define a repackaged jar dependency by doing the following in their Gradle build script
With
downloadInBuck = true
, this causes a failure after OkBuck runs with the following exception (since this target doesn't exist)With
downloadInBuck = false
a different exception occurs when trying to symlink the downloaded jar to the existing aarIt appears that what is happening is that OkBuck in the dependency processing step is collecting both the AAR and the JAR from the artifact because they have the same name, then either trying to make a duplicate symlink or download a jar that doesn't exist
I did a bit of (brutish) exploration here NickFirmani@b8a5c06 to try and fix this, I don't think that this is quite the correct approach, but it does solve the problem, just preferring the AAR over the JAR if both exist.
The text was updated successfully, but these errors were encountered: