В проекте «приложение» разрешенная зависимость библиотеки сервисов Google Play зависит от другого

1

ОШИБКА. В проекте "приложение" разрешенная зависимость библиотеки служб Google Play зависит от другой в конкретной версии (например, "[15.0. 1]", но не разрешается в этой версии. Поведение, демонстрируемое библиотекой, будет неизвестно.

Ошибка зависимости: com.google.android.gms: play-services-flags: 15.0.1 → com.google.android.gms: play-services-base @[15.0.1], но версия play-services-base была 16.0.1.

apply plugin: 'com.android.application'
apply plugin: 'com.google.gms.google-services'

android {
    compileSdkVersion 26
    defaultConfig {
        applicationId "com.example.android.studentattendance"
        minSdkVersion 22
        targetSdkVersion 26
        versionCode 1
        versionName "1.0"
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])

    implementation 'com.google.android.gms:play-services-auth:9.8.0'
    implementation 'com.google.android.gms:play-services-location:16.0.1'
    implementation 'com.android.support:appcompat-v7:26.1.0'
    implementation 'com.android.support.constraint:constraint-layout:1.1.3'
    implementation 'com.google.firebase:firebase-auth:16.0.3'
    implementation 'com.google.firebase:firebase-core:16.0.1'
    implementation 'com.google.android.gms:play-services-auth-base:16.1.0'
    implementation 'com.google.android.gms:play-services-maps:16.1.0'
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'com.android.support.test:runner:1.0.2'
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
}
Теги:
android-studio
android-gradle
google-play-services
dependencies

2 ответа

0

реализация 'com.google.android.gms: play-services-auth: 16.0.1' реализация 'com.google.android.gms: play-services-base: 16.1.0'

implementation 'com.android.support:appcompat-v7:26.1.0'
implementation 'com.google.android.gms:play-services-flags:16.0.1'
implementation 'com.google.android.gms:play-services-basement:16.2.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
implementation 'com.google.firebase:firebase-auth:16.2.1'
implementation 'com.google.firebase:firebase-core:16.0.8'
implementation 'com.google.android.gms:play-services-maps:16.1.0'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
implementation 'com.android.support:support-annotations:28.0.0'
  • 0
    Не могли бы вы уточнить, что именно вы сделали. Ответ, если это ответ, не ясен вообще.
0

Измените свой список зависимостей.

зависимости {реализация fileTree (dir: 'libs', include: ['*.jar'])

implementation 'com.google.android.gms:play-services-auth:16.0.1'
implementation 'com.google.android.gms:play-services-base:16.1.0'
implementation 'com.google.android.gms:play-services-location:16.0.1'
implementation 'com.android.support:appcompat-v7:26.1.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
implementation 'com.google.firebase:firebase-auth:16.0.3'
implementation 'com.google.firebase:firebase-core:16.0.1'
implementation 'com.google.android.gms:play-services-maps:16.1.0'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'

}

  • 0
    все еще получаю ту же ошибку

Ещё вопросы

Сообщество Overcoder
Наверх
Меню