Could not determine the dependencies of task ':app:processDebugResources'.
Could not resolve all task dependencies for configuration ':app:debugRuntimeClasspath'. Could not resolve com.facebook.android:facebook-login:[5,6).
Required by: project:app > Failed to list versions for com.facebook.android:facebook-login. > Unable to load Maven meta-data from https://google.bintray.com/exoplayer/com/facebook/android/facebook-login/maven-metadata.xml . > Could not get resource 'https://google.bintray.com/exoplayer/com/facebook/android/facebook-login/maven-metadata.xml'. > Could not GET 'https://google.bintray.com/exoplayer/com/facebook/android/facebook-login/maven-metadata.xml'. Received status code 502 from server: Bad Gateway
app-level/buildgradle
def localProperties = new Properties()
def localPropertiesFile = rootProject.file('local.properties')
if (localPropertiesFile.exists()) {
localPropertiesFile.withReader('UTF-8') { reader ->
localProperties.load(reader)
}
}
def flutterRoot = localProperties.getProperty('flutter.sdk')
if (flutterRoot == null) {
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the
local.properties file.")
}
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
if (flutterVersionCode == null) {
flutterVersionCode = '1'
}
def flutterVersionName = localProperties.getProperty('flutter.versionName')
if (flutterVersionName == null) {
flutterVersionName = '1.0'
}
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
apply plugin: 'com.google.gms.google-services'
android {
compileSdkVersion 28
sourceSets {
main.java.srcDirs += 'src/main/kotlin'
}
lintOptions {
disable 'InvalidPackage'
}
defaultConfig {
// TODO: Specify your own unique Application ID
(https://developer.android.com/studio/build/application-id.html).
applicationId "com.deligence.hookup4u2"
minSdkVersion 21
targetSdkVersion 28
versionCode flutterVersionCode.toInteger()
versionName flutterVersionName
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
// Use code below for production build
// For debug mode you need to comment above lines of code
// Issue with 'libflutter.so'
ndk {
abiFilters 'arm64-v8a', 'armeabi-v7a', 'x86'
}
}
buildTypes {
release {
// TODO: Add your own signing config for the release build.
// Signing with the debug keys for now, so `flutter run --release` works.
signingConfig signingConfigs.debug
}
}
}
flutter {
source '../..'
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
testImplementation 'junit:junit:4.12'
androidTestImplementation 'androidx.test:runner:1.1.1'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1'
implementation 'com.google.firebase:firebase-analytics:17.2.2'
implementation 'com.facebook.android:facebook-login:[5,6)'
implementation 'com.google.firebase:firebase-messaging:20.1.6'
}
projectlevel/buildGradle
buildscript {
ext.kotlin_version = '1.3.50'
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.5.0'
classpath 'com.google.gms:google-services:4.3.3'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
allprojects {
repositories {
google()
jcenter()
}
}
rootProject.buildDir = '../build'
subprojects {
project.buildDir = "${rootProject.buildDir}/${project.name}"
}
subprojects {
project.evaluationDependsOn(':app')
}
task clean(type: Delete) {
delete rootProject.buildDir
}
Problem that google.bintray.com is down but version of com.facebook.android:facebook-login is not specified strictly.
This [5,6) mean it has versions range Gradle Declaring Versions and Ranges
Search for versions of com.facebook.android:facebook-login Maven search . We have 5.15.x
Constrain your transitive dependency with maximum possible version 5.15.3
Edit your project app/build.gradle :
dependencies {
...
constraints {
implementation('com.facebook.android:facebook-login') {
version {
strictly '5.15.3'
}
}
}
}
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.