The build fails at the moment with:
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Could not find com.apollographql.apollo:apollo-android-support:1.3.2.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/com/apollographql/apollo/apollo-android-support/1.3.2/apollo-android-support-1.3.2.pom
- https://jcenter.bintray.com/com/apollographql/apollo/apollo-android-support/1.3.2/apollo-android-support-1.3.2.pom
This is because we are merging the bintray packages and this broke the jcenter sync. We asked bintray to restore it.
In the meantime, you can download the artifacts from https://dl.bintray.com/apollographql/android/
// for the plugin
buildscript {
repositories {
maven { url = uri("https://dl.bintray.com/apollographql/android/") }
// put jcenter() below
jcenter()
}
}
// for the libs
allprojects {
repositories {
maven { url = uri("https://dl.bintray.com/apollographql/android/") }
// put jcenter() below
jcenter()
}
}
I'll post as soon as jcenter is up again.
Weirdly we are still seeing missing deps even when hard-coding bintray:
> Could not resolve all task dependencies for configuration ':xxx:debugRuntimeClasspath'.
> Could not find com.apollographql.apollo:apollo-runtime:1.4.4.
Required by:
project :xxx > project :app > project :api
> Could not find com.apollographql.apollo:apollo-rx2-support:1.4.4.
Required by:
project :xxxx > project :app > project :api
Even though these artifacts are very much present:
https://dl.bintray.com/apollographql/android/com/apollographql/apollo/apollo-runtime/1.4.4/
@tir38 did you put maven { url = uri("https://dl.bintray.com/apollographql/android/") } above jcenter() ? There might be caching involved letting jcenter() think the artifact is there while it's not.
Gradle has repositories under buildscript and subproject. Make sure to put the above maven url under both.
@martinbonnin yep, even did a full nuke of all 3rd party deps in ~/.gradle/caches.
@tasomaniac bingo. I forgot to add to allprojects block too. Thanks
@tir38 could you summarize what worked for you? We use the buildscript method to include the plugin and that doesn't seem to work.
@adilfulara to make this work you should avoid using the plugins { } block and instead do the following 3 things:
classpath("com.apollographql.apollo:apollo-gradle-plugin:${Versions.apollo}") to your buildscript { dependencies { } } blockapply(plugin = "com.apollographql.apollo") in your gradle modulesconfigure<ApolloExtension> { } instead of apollo {}Note: the above assume you are using Kotlin DSL, Groovy DSL will be slightly different.
The plugins {} block always tries to use the plugins.gradle.org repo, regardless of what you put in your repositories {} blocks.
i did a fresh checkout of our project that uses 1.2.x and was losing my mind why gradle cannot find it from the public repos...so when i added
maven { url = uri("https://dl.bintray.com/apollographql/android/") }
above jcenter() in repositories block (per @martinbonnin) everything's all good.
~what happened?~ ok apparently i don't know how to read; it was just explained in the first post.
@adilfulara to make this work you should avoid using the
plugins { }block and instead do the following 3 things:
- add
classpath("com.apollographql.apollo:apollo-gradle-plugin:${Versions.apollo}")to yourbuildscript { dependencies { } }block- apply the plugin using
apply(plugin = "com.apollographql.apollo")in your gradle modules- configure using
configure<ApolloExtension> { }instead ofapollo {}Note: the above assume you are using Kotlin DSL, Groovy DSL will be slightly different.
The
plugins {}block always tries to use theplugins.gradle.orgrepo, regardless of what you put in yourrepositories {}blocks.
Thank you ! It worked
Jcenter has been enabled again and the situation should progressively go back to normal. From what I have seen, the different version appear progressively. Let me know if you still have issues.
Sorry again for the inconvenience. This was a one time thing and hopefully maintaining the packages will be easier in tthe future.
Most helpful comment
Jcenter has been enabled again and the situation should progressively go back to normal. From what I have seen, the different version appear progressively. Let me know if you still have issues.
Sorry again for the inconvenience. This was a one time thing and hopefully maintaining the packages will be easier in tthe future.