Reputation: 4484
I'm using Gradle 6.9 (this git project won't build on anything >= Gradle 7 so the Gradle has to be 6.9 or lower). It also failed w/ the same error using Gradle 6.8.3.
Here is the error when I gradle clean build
:
Task :wallet:preDevDebugBuild FAILED
FAILURE: Build failed with an exception.
What went wrong:
Execution failed for task ':wallet:preDevDebugBuild'.
Could not resolve all files for configuration ':wallet:devDebugCompileClasspath'.
Could not resolve com.google.guava:guava:33.3.1-android.
Required by:
project :wallet
The consumer was configured to find an API of a component, as well as attribute 'com.android.build.api.attributes.BuildTypeAttr' with value 'debug', attribute 'flavor' with value 'dev', attribute 'com.android.build.gradle.internal.dependency.AndroidTypeAttr' with value 'Aar'. However we cannot choose between the following variants of com.google.guava:guava:33.3.1-android:
- androidApiElements
- jreApiElements
I have tried referencing other repositiories in my project level build.gradle. All have failed :
buildscript {
repositories {
// mavenLocal()
//maven { url "https://repo1.maven.org/maven2" }
mavenCentral()
google()
}
}
allprojects {
repositories {
// mavenLocal()
// maven { url "https://repo1.maven.org/maven2" }
mavenCentral()
google()
}
}
Here are my (some) subproject dependencies (edited for brevity):
dependencies {
implementation 'org.bitcoinj:bitcoinj-core:0.16.4'
implementation 'com.google.guava:guava:33.3.1-android'
// https://mvnrepository.com/artifact/com.google.guava/guava
//implementation 'com.google.guava:guava:33.4.0-android'
implementation 'com.squareup.moshi:moshi:1.11.0'
implementation 'org.slf4j:slf4j-api:2.0.9'
implementation 'com.github.tony19:logback-android:3.0.0'
}
I know the artifact exists: https://repo1.maven.org/maven2/com/google/guava/guava/33.3.1-android/
and... https://central.sonatype.com/artifact/com.google.guava/guava/33.3.1-android/versions
Is this a repository problem? Or is it due to me lacking some Gradle skills?
Upvotes: 0
Views: 196