[英]org.gradle.api.GradleException: Please fix the version conflict either
I'm building an android app with Firebase and Maps APIs but I'm getting the following error: 我正在使用Firebase和Maps API构建一个Android应用程序,但出现以下错误:
Please fix the version conflict either by updating the version of the google-services plugin (information about the latest version is available at https://bintray.com/android/android-tools/com.google.gms.google-services/ ) or updating the version of com.google.android.gms to 12.0.1. 请通过更新google-services插件的版本来解决版本冲突(有关最新版本的信息, 请访问https://bintray.com/android/android-tools/com.google.gms.google-services/ )或将com.google.android.gms的版本更新为12.0.1。
Here's what I have in the build.gradle module:app file. 这是我在build.gradle模块中的内容:app文件。 Any chance someone can help identify what conflict is happening here?
有人可以帮助您确定这里发生了什么冲突吗?
apply plugin: 'com.android.application'
android {
compileSdkVersion 26
buildToolsVersion '26.0.2'
defaultConfig {
applicationId "com.simcoder.uber"
minSdkVersion 16
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner
"android.support.test.runner.AndroidJUnitRunner"
multiDexEnabled true
}
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'
})
//noinspection GradleCompatible
compile 'com.android.support:appcompat-v7:26.1.0'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
compile 'com.google.firebase:firebase-core:12.0.1'
compile 'com.google.firebase:firebase-database:11.6.0'
compile 'com.google.firebase:firebase-auth:11.6.0'
compile 'com.google.firebase:firebase-storage:11.6.0'
compile 'com.firebase:geofire-android:2.1.1'
compile 'com.google.android.gms:play-services:12.0.1'
compile 'com.github.bumptech.glide:glide:4.0.0'
compile 'com.android.support:design:26.1.0'
compile 'com.android.support:cardview-v7:26.1.0'
compile 'com.github.jd-alexander:library:1.1.0'
compile 'com.paypal.sdk:paypal-android-sdk:2.15.3'
compile 'com.google.gms:google-services:3.3.0'
testCompile 'junit:junit:4.12'
}
apply plugin: 'com.google.gms.google-services'
解决了这个问题,需要将Firebase versions
更新到最新Firebase versions
,并删除了 compile 'com.google.android.gms:play-services:12.0.1'
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.