0

when i want to build my project, an error pops up and It says: Exectuion failed for task 'app:processDebugGoogleServices'.

This is the full Error:

Error:Execution failed for task ':app:processDebugGoogleServices'.
> 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 11.0.4.

These are my gradle files.

    apply plugin: 'com.android.application'

android {
    signingConfigs {

    }
    dexOptions {
        javaMaxHeapSize "2g"
    }
    compileSdkVersion 25
    buildToolsVersion '26.0.2'
    defaultConfig {
        applicationId "org.x.x"
        minSdkVersion 15
        targetSdkVersion 25
        versionCode 2
        versionName "1.1"
        multiDexEnabled true
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
    productFlavors {
    }
}

dependencies {
    **implementation 'com.google.android.gms:play-services-maps:11.6.0'**
    compile fileTree(include: ['*.jar'], dir: 'libs')
    compile 'com.google.code.gson:gson:2.5'
    compile 'com.android.support:appcompat-v7:23.4.0'
    compile 'com.android.support:design:23.4.0'
    compile 'com.android.support:support-v4:23.4.0'
    compile 'com.loopj.android:android-async-http:1.4.9'
    compile 'com.squareup.picasso:picasso:2.5.2'
    compile 'com.google.firebase:firebase-auth:11.0.4'
    compile 'com.google.firebase:firebase-messaging:11.0.4'
    compile 'com.google.firebase:firebase-core:11.0.4'
    compile 'com.google.firebase:firebase-analytics:11.0.4'
    compile 'com.google.android.gms:play-services-auth:11.6.0'
    compile 'com.android.support.constraint:constraint-layout:+'
    compile 'com.facebook.android:facebook-android-sdk:[4,5)'
    compile 'com.facebook.android:facebook-share:[4,5)'
    compile 'com.ToxicBakery.viewpager.transforms:view-pager-transforms:1.2.32@aar'
    compile 'org.apache.commons:commons-lang3:3.4'
    compile 'com.getbase:floatingactionbutton:1.9.0'
    compile 'com.ms-square:expandableTextView:0.1.4'
    compile 'com.android.support:multidex:1.0.1'
    testCompile 'junit:junit:4.12'
}

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

and the other gradle file

buildscript {
    repositories {
        jcenter()
        maven {
            url 'https://maven.google.com/'
            name 'Google'
        }
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:3.0.0'
        classpath 'com.google.gms:google-services:3.1.1'

        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        jcenter()
        mavenCentral()
        google()
    }
}

task clean(type: Delete) {
    delete rootProject.buildDir
}

In the first gradle, implementation 'com.google.android.gms:play-services-maps:11.6.0' is throwing an error that says:

All gms/firebase libraries must use the exact same version specification (mixing versions can lead to runtime crashes). Found versions 11.6.0, 11.0.4. Examples include com.google.android.gms:play-services-auth:11.6.0 and com.google.firebase:firebase-analytics:11.0.4

What am I doing wrong?

1 Answers1

0

I RESOLVED THIS.

THE ONLY THING YOU NEED TO DO IS WRITE THE SAME VERSION OF:

implementation 'com.google.android.gms:play-services-maps:***11.6.0**'*

TO THE OTHERS LIBRARIES FROM GOOGLE AND FIREBASE