0

This is the error which keeps showing:

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 9.2.0.

This is my build.gradle file:

dependencies {
    compile fileTree(include: ['*.jar'], dir: 'libs')
    androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
        compile "com.google.android.gms:play-services-gcm:9.2.0"
        exclude group: 'com.android.support', module: 'support-annotations'
    })
    compile 'com.google.android.gms:play-services-gcm:11.0.0'
    compile 'com.facebook.android:facebook-android-sdk:4.26.+'
    compile 'com.android.support:appcompat-v7:26.0.2-alpha'
    compile 'com.android.support:design:26.+'
    compile 'com.google.firebase:firebase-auth:11.0.2'
    compile 'com.android.support.constraint:constraint-layout:1.0.0-alpha7'
    compile 'com.android.support:support-v4:26.+'
    compile 'com.google.firebase:firebase-database:10.0.1'
    testCompile 'junit:junit:4.12'
}
apply plugin: 'com.google.gms.google-services'
Thomas Vos
  • 12,271
  • 5
  • 33
  • 71

1 Answers1

0

error is because you are using different versions of play services make following changes

dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
    compile "com.google.android.gms:play-services-gcm:11.0.0"<---- change
    exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.google.android.gms:play-services-gcm:11.0.0'
compile 'com.facebook.android:facebook-android-sdk:4.26.+'
compile 'com.android.support:appcompat-v7:26.0.2-alpha'
compile 'com.android.support:design:26.+'
compile 'com.google.firebase:firebase-auth:11.0.2'
compile 'com.android.support.constraint:constraint-layout:1.0.0-alpha7'
compile 'com.android.support:support-v4:26.+'
compile 'com.google.firebase:firebase-database:11.0.0'<----- change
testCompile 'junit:junit:4.12'
} 
akshay_shahane
  • 4,423
  • 2
  • 17
  • 30