1
我想FirebaseUI驗證添加到我的項目,但我不斷收到同步失敗是這樣的:FirebaseUI AUTH錯誤:無法解析:com.android.support:xxx:26.0.1
Error:A problem occurred configuring project ':app'.
> Could not resolve all dependencies for configuration ':app:_debugApkCopy'.
> Could not find com.android.support:appcompat-v7:26.0.1.
Required by:
project :app
> Could not find com.android.support:support-compat:26.0.1.
Required by:
project :app
> Could not find com.android.support.constraint:constraint-layout:1.1.0-beta1.
Required by:
project :app
> Could not find com.android.support:design:26.0.1.
Required by:
project :app > com.firebaseui:firebase-ui-auth:2.3.0
> Could not find com.android.support:customtabs:26.0.1.
Required by:
project :app > com.firebaseui:firebase-ui-auth:2.3.0
> Could not find com.android.support.constraint:constraint-layout:1.1.0-beta1.
Required by:
project :app > com.firebaseui:firebase-ui-auth:2.3.0
> Could not find com.android.support:cardview-v7:26.0.1.
Required by:
project :app > com.firebaseui:firebase-ui-auth:2.3.0
> Could not find com.android.support:appcompat-v7:26.0.1.
Required by:
project :app > com.google.android.gms:play-services:11.0.4 > com.google.android.gms:play-services-cast:11.0.4 > com.android.support:mediarouter-v7:25.2.0
> Could not find com.android.support:support-compat:26.0.1.
Required by:
project :app > com.google.android.gms:play-services:11.0.4 >
com.google.android.gms:play-services-basement:11.0.4 >
com.android.support:support-v4:25.2.0
project :app > com.google.android.gms:play-services:11.0.4 >
com.google.android.gms:play-services-cast:11.0.4 >
com.android.support:mediarouter-v7:25.2.0 > com.android.support:palette-v7:25.2.0
project :app > com.google.android.gms:play-services:11.0.4 >
com.google.android.gms:play-services-basement:11.0.4 >
com.android.support:support-v4:25.2.0 > com.android.support:support-media-
compat:25.2.0
project :app > com.google.android.gms:play-services:11.0.4 >
com.google.android.gms:play-services-basement:11.0.4 >
com.android.support:support-v4:25.2.0 > com.android.support:support-core-utils:25.2.0
project :app > com.google.android.gms:play-services:11.0.4 >
com.google.android.gms:play-services-basement:11.0.4 >
com.android.support:support-v4:25.2.0 > com.android.support:support-core-ui:25.2.0
project :app > com.google.android.gms:play-services:11.0.4 >
com.google.android.gms:play-services-basement:11.0.4 >
com.android.support:support-v4:25.2.0 > com.android.support:support-fragment:25.2.0
我的應用程序級的build.gradle看起來是這樣的:
apply plugin: 'com.android.application'
android {
compileSdkVersion 26
buildToolsVersion "26.0.1"
defaultConfig {
applicationId "com.chalker.chalker"
minSdkVersion 23
targetSdkVersion 26
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:26.0.1'
compile "com.android.support:support-compat:26.0.1"
compile 'com.android.support.constraint:constraint-layout:1.0.2'
testCompile 'junit:junit:4.12'
compile 'com.google.android.gms:play-services:11.0.4'
compile 'com.firebaseui:firebase-ui-auth:2.3.0'
}
apply plugin: 'com.google.gms.google-services'
我的項目級的build.gradle:
buildscript {
repositories {
maven {
url "https://maven.google.com"
}
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.3.3'
classpath 'com.google.gms:google-services:3.1.0'
}
}
allprojects {
repositories {
jcenter()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
我在這裏讀到類似的問題,做了對他人解決問題的建議,但我只是無法讓我的工作... 感謝您提前的每一個幫助!從buildscript/repositories
maven {
url "https://maven.google.com"
}
到allprojects/repositories
: 尤
非常感謝您的快速回答,解決了問題! – wfmn17