Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

play-services-measurement-based requested with several versions

Error:Failed to notify dependency resolution listener. The library com.google.android.gms:play-services-measurement-base is being requested by various other libraries at [[15.0.2,15.0.2], [15.0.4,15.0.4]], but resolves to 15.0.4. Disable the plugin and check your dependencies tree using ./gradlew :app:dependencies.


apply plugin: 'com.android.application'

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

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    implementation 'com.android.support:appcompat-v7:26.1.0'
    implementation 'com.android.support.constraint:constraint-layout:1.1.0'

    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'com.android.support.test:runner:1.0.1'
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'
    compile 'com.android.support:design:26.1.0'
    implementation 'com.google.firebase:firebase-core:15.0.4'
    implementation 'com.google.android.gms:play-services-location:15.0.4'
    implementation 'com.google.firebase:firebase-ads:15.0.1'
    implementation 'com.google.firebase:firebase-core:16.0.0'
    implementation 'com.google.firebase:firebase-auth:16.0.0'
    implementation 'com.firebaseui:firebase-ui:0.6.2'
}



apply plugin: 'com.google.gms.google-services'
like image 877
Jayesh Thakkar Avatar asked Jun 13 '18 18:06

Jayesh Thakkar


1 Answers

Do you have the classpath 'com.google.gms:google-services:4.0.1'?

It is 4.0.1! I updated it from 4.0.0 to 4.0.1 and it is ok!

If it still doesn't work, you can do this, manually add and not use the plugin

like image 62
Lotus Yang Avatar answered Sep 28 '22 08:09

Lotus Yang