-
Notifications
You must be signed in to change notification settings - Fork 16
Description
I'm trying to use this project to build an Android app, which I read is not yet supported; but my build already fails in the download step.
I don't understand gradle things very well, so I may be misunderstanding some things, but what I found is the following:
My verification-metadata.xml contains the following:
<component group="androidx.compose.animation" name="animation-core-android" version="1.7.8">
<artifact name="animation-core-android-1.7.8.module">
<sha256 value="3ce792d09bcf03a1cc1d55f1424822f0961ec9bb019450d2f036c7af1205a10c" origin="Generated by Gradle"/>
</artifact>
<artifact name="animation-core-release.aar">
<sha256 value="8237488870c73e9b66f7ecab5ec1855b0cafc023b0a937f3f7c65602e2c8c7b2" origin="Generated by Gradle"/>
</artifact>
</component>
Now buildGradleApplication tries to download the file from https://maven.google.com/androidx/compose/animation/animation-core-android/1.7.8/animation-core-release.aar, but cannot find it:
nix log
nix log /nix/store/1fk4s0c35jc6m1mmk8kbra34ny9z9jbr-animation-core-release.aar.drv
warning: The interpretation of store paths arguments ending in `.drv` recently changed. If this command is now failing try again with '/nix/store/1fk4s0c35jc6m1mmk8kbra34ny9z9jbr-animation-core-release.aar.drv^*'
Downloading animation-core-release.aar from https://plugins.gradle.org/m2/androidx/compose/animation/animation-core-android/1.7.8/animation-core-release.aar
error checking the existence of https://plugins.gradle.org/m2/androidx/compose/animation/animation-core-android/1.7.8/animation-core-release.aar:
curl: (22) The requested URL returned error: 404
Downloading animation-core-release.aar from https://repo1.maven.org/maven2/androidx/compose/animation/animation-core-android/1.7.8/animation-core-release.aar
error checking the existence of https://repo1.maven.org/maven2/androidx/compose/animation/animation-core-android/1.7.8/animation-core-release.aar:
curl: (22) The requested URL returned error: 404
Downloading animation-core-release.aar from https://maven.google.com/androidx/compose/animation/animation-core-android/1.7.8/animation-core-release.aar
error checking the existence of https://maven.google.com/androidx/compose/animation/animation-core-android/1.7.8/animation-core-release.aar:
curl: (22) The requested URL returned error: 404
File animation-core-release.aar was not found with hash sha256-gjdIiHDHPptm9+yrXsGFWwyvwCOwqTfz98ZWAuLIx7I= on any of the given urls
After some digging, I figured out that the animation-core-android-1.7.8.module file mentioned in the lockfile can be downloaded at https://maven.google.com/androidx/compose/animation/animation-core-android/1.7.8/animation-core-android-1.7.8.module is a json file that contains metadata about the package; and there's information about the files with a name and a url attribute:
cat animation-core-android-1.7.8.module | jq '.variants | .[] | .files | .[] | select(.name == "animation-core-release.aar")'
{
"name": "animation-core-release.aar",
"url": "animation-core-android-1.7.8.aar",
"size": 1473986,
"sha512": "6468b1cef3c92e2814a53ff439a1c25e5eb12a60dd27d8b667bf21ed48a17301e01e81f720a9ea7509ce62562688be0f0af9f201c97e25a3ece3dc50c98f75ff",
"sha256": "8237488870c73e9b66f7ecab5ec1855b0cafc023b0a937f3f7c65602e2c8c7b2",
"sha1": "9f78d4f11c4b89774095e314ded5fed47babf8f5",
"md5": "a67f0d0327d26d9d02efb83dd736ac4e"
}
{
"name": "animation-core-release.aar",
"url": "animation-core-android-1.7.8.aar",
"size": 1473986,
"sha512": "6468b1cef3c92e2814a53ff439a1c25e5eb12a60dd27d8b667bf21ed48a17301e01e81f720a9ea7509ce62562688be0f0af9f201c97e25a3ece3dc50c98f75ff",
"sha256": "8237488870c73e9b66f7ecab5ec1855b0cafc023b0a937f3f7c65602e2c8c7b2",
"sha1": "9f78d4f11c4b89774095e314ded5fed47babf8f5",
"md5": "a67f0d0327d26d9d02efb83dd736ac4e"
}
so the animation-core-release.aar name is mapped to animation-core-android-1.7.8.aar url and indeed https://maven.google.com/androidx/compose/animation/animation-core-android/1.7.8/animation-core-android-1.7.8.aar exists.
Now I wonder if this translation could be done by buildGradlePackage (if that is even what is supposed to happen, I'm not sure how the semantics is supposed to be).