Reputation: 30855
Does anyone know what the proper way to implement Crash report
using Firebase
in Android
application?
I have read Firebase crashlytics
doc in that mention implement Fabric.io
. Fabric.io
is deprecate and in there document mention removed fabric.io
dependency.
Firebase
https://firebase.google.com/docs/crashlytics/get-started?platform=android
Fabric.io reference
https://docs.fabric.io/android/examples/sampleapp/index.html
Without fabric.io
dependency I am getting below error
java.lang.RuntimeException: Unable to get provider com.crashlytics.android.CrashlyticsInitProvider: io.fabric.sdk.android.services.concurrency.UnmetDependencyException: The Crashlytics build ID is missing. This occurs when Crashlytics tooling is absent from your app's build configuration. Please review Crashlytics onboarding instructions and ensure you have a valid Crashlytics account.`
Note: Please compare the steps in both reference, I have go through all the links but didn't find the proper way that's why I am asking here.
I am sure no 1 go through the links, that's why getting down vote great. I have attached the Firebase and Fabric.io document steps screen
Upvotes: 5
Views: 14760
Reputation: 30855
Late post
Here is the solution, first of all remove all the fabric.io related reference and code.
In the main gradle.build project level
buildscript {
ext.kotlin_version = '1.4.0'
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:4.0.2'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
// Add this line
classpath 'com.google.firebase:firebase-crashlytics-gradle:2.3.0'
}
}
Next, in the build.gradle app level
apply plugin: 'com.google.firebase.crashlytics' // add this line at top
and in the dependency area
dependencies {
implementation 'com.google.firebase:firebase-crashlytics:17.2.2' // add this line
}
Upvotes: 2
Reputation: 161
One of the problems is that the Google page omits the android tutorial in languages other than English. (it can happen by bug. It happened to me.) Ok ... I'm not very experienced with Crashlytics, and looking to make the migration I came across exactly these links that you showed and I was also confused. But as I understand it, Fabric Crashlytics was acquired and incorporated into Firebase, so the first tutorial is old, when there was a need for the Fabric library to implement Crashlytics in Firebase. The second tutorial does not seem to want to specify which new libraries will be implemented. The best tutorial I found is this: Oficial: https://firebase.google.cn/docs/crashlytics/upgrade-sdk?platform=android#kotlin+ktx_5 or: https://medium.com/@onkart10/migrating-from-fabric-to-firebase-crashlytics-e8819933c484
I hope it helps others.
Upvotes: 0
Reputation: 9082
If you really want to remove the Fabric SDK from your app and use the Firebase SDK, Follow the Upgrade to the Firebase Crashlytics SDK
This guide describes how to upgrade to the new SDK from the Fabric Crashlytics SDK. It describes the changes that come with the new APIs, the reason for the changes, and how to update your code, if required.
docs.fabric.io you can get the following information, So I don't know why you have so many down votes, this is a legit question IMHO. Maybe because you didn't do this research yourself which I just did here.
You can continue using the Fabric Crashlytics SDK in your apps until a deprecation date is announced. Once the Fabric Crashlytics SDK deprecation date is announced you will need to upgrade to the new Firebase Crashlytics SDK. Old versions of your app still using the Fabric Crashlytics SDK will not break once it’s deprecated, however they will no longer submit crash reports.
But it seems like it will just continue to work as per normal after this date until further notice. Just leave it the way it is.
Upvotes: 1
Reputation: 1675
Are you talking about this?
apply plugin: 'io.fabric'
According to the documentation in here,
Crashlytics has been integrated into Firebase, with new Firebase-only features. New apps should use Crashlytics in Firebase to get access to the latest updates and features. Fabric Crashlytics and the Fabric dashboard will be available until March 31, 2020 for existing users.
My guess is that, it might be - Let's call it grace period ;) up until every other user migrates it and they migrate every other tool from Fabric.
By the end of March 31, 2020 everything related to Fabric might be removed. Hope I answered what you were stating about.
Upvotes: 0