Firebase did an update to the SDK:
Firebase Android SDKs now have independent version numbers, allowing for more frequent, flexible updates.
Update all your Firebase dependencies to use the latest version:
Firebase Core com.google.firebase:firebase-core:15.0.2
Ads com.google.firebase:firebase-ads:15.0.0
Analytics com.google.firebase:firebase-analytics:15.0.2
App Indexing com.google.firebase:firebase-appindexing:15.0.0
Authentication com.google.firebase:firebase-auth:15.1.0
Cloud Firestore com.google.firebase:firebase-firestore:16.0.0
Cloud Functions com.google.firebase:firebase-functions:15.0.0
Cloud Messaging com.google.firebase:firebase-messaging:15.0.2
Cloud Storage com.google.firebase:firebase-storage:15.0.2
Crash Reporting com.google.firebase:firebase-crash:15.0.2
Crashlytics com.crashlytics.sdk.android:crashlytics:2.9.1
Invites com.google.firebase:firebase-invites:15.0.1
Performance Monitoring com.google.firebase:firebase-perf:15.1.0
Realtime Database com.google.firebase:firebase-database:15.0.0
Remote Config com.google.firebase:firebase-config:15.0.2
More information is here:
https://firebase.google.com/support/release-notes/android
Please also update google-services
plugin:
classpath 'com.google.gms:google-services:3.3.1'
You can find the latest google-services clicking HERE
Also check this link to understand the changes and follow the steps listed in the article:
Announcing the new SDK Versioning
EDITED ON: 27 NOVEMBER 2019
As of today, the latest version for google-services
Plugin is 4.3.3
. So, your dependency would look like
classpath 'com.google.gms:google-services:4.3.3'
In my case problem is same.I followed below steps:
1.build.gradle(gradle)
change :
classpath 'com.google.gms:google-services:3.2.0'
To :
classpath 'com.google.gms:google-services:3.2.1'
2.build.gradle(module)
implementation 'com.google.firebase:firebase-core:15.0.2'
implementation 'com.google.firebase:firebase-messaging:15.0.2'
implementation 'com.google.android.gms:play-services-maps:15.0.1'
for google location and places :
implementation 'com.google.android.gms:play-services-location:15.0.1'
implementation 'com.google.android.gms:play-services-places:15.0.1'
The problem is caused because Firebase started versioning the libraries separately. Updating everything to latest version solves the issue.
Update the google play gradle plugin version to latest version, currently 4.0.1
.
In project level build.gradle
file:
classpath 'com.google.gms:google-services:4.0.1'
Information about latest version of google gradle plugin is available at:
https://bintray.com/android/android-tools/com.google.gms.google-services/
And use the latest versions of individual libraries in app level build.gradle
file:
implementation 'com.google.android.gms:play-services-vision:15.0.2'
implementation 'com.google.android.gms:play-services-ads:15.0.1'
implementation 'com.google.firebase:firebase-messaging:15.0.2'
Information about latest versions of individual libraries available at:
https://firebase.google.com/support/release-notes/android and https://developers.google.com/android/guides/setup
For those who are facing this issue with the latest Firebase versions as today Nov 8th, 2018. I fixed the conflict by downgrading the firebase-ads
library while keeping the rest using the latest versions.
I changed from:
googleImplementation "com.google.firebase:firebase-core:16.0.5"
googleImplementation "com.google.firebase:firebase-ads:17.0.0" //CONFLICTING VERSION
googleImplementation "com.google.firebase:firebase-config:16.1.0"
googleImplementation "com.google.firebase:firebase-messaging:17.3.4"
To:
googleImplementation "com.google.firebase:firebase-core:16.0.5"
googleImplementation "com.google.firebase:firebase-ads:15.0.1" //WORKING VERSION
googleImplementation "com.google.firebase:firebase-config:16.1.0"
googleImplementation "com.google.firebase:firebase-messaging:17.3.4"
Also, note that on the Project's root build.gradle
I'm using the following google services version com.google.gms:google-services:4.2.0
.
I tried a few approaches, analyzing the dependencies tree, excluding the modules with the mentioned program, but they ended up crashing on runtime. The safest solution I found was using the 15.0.1
for the firebase-ads
Latest Firebase SDK versions
Service Gradle dependency
Firebase Core com.google.firebase:firebase-core:16.0.1
Ads com.google.firebase:firebase-ads:15.0.1
Analytics com.google.firebase:firebase-analytics:16.0.0
App Indexing com.google.firebase:firebase-appindexing:16.0.1
Authentication com.google.firebase:firebase-auth:16.0.2
Cloud Firestore com.google.firebase:firebase-firestore:17.0.2
Cloud Functions com.google.firebase:firebase-functions:16.0.1
Cloud Messaging com.google.firebase:firebase-messaging:17.0.0
Cloud Storage com.google.firebase:firebase-storage:16.0.1
Crash Reporting com.google.firebase:firebase-crash:16.0.0
Crashlytics com.crashlytics.sdk.android:crashlytics:2.9.3
Invites com.google.firebase:firebase-invites:16.0.1
ML Kit: Model Interpreter com.google.firebase:firebase-ml-model-interpreter:16.0.0
ML Kit: Vision com.google.firebase:firebase-ml-vision:16.0.0
ML Kit: Image Labeling com.google.firebase:firebase-ml-vision-image-label-model:15.0.0
Performance Monitoring com.google.firebase:firebase-perf:16.0.0
Realtime Database com.google.firebase:firebase-database:16.0.1
Remote Config com.google.firebase:firebase-config:16.0.0
Cloud Firestore version 17.0.2
gRPC requirement updated from 1.8.0 to 1.12.0. This allows quicker failover between Wi-Fi and cellular networks.
Invites version 16.0.1
Fixed incompatibility with firebase-core 16.0.1.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With