Firebase Crashlytics not working without Fabric API key
Asked Answered
S

3

11

I got an android app where Fabric Crashytics is installed. I've followed the official guide to setup Firebase Crashlytics and linked the Fabric and Firebase accounts (AFAIK Firebase acquired Fabric recently). So in particular I removed the Fabric API key with <meta-data/> tag in manifest.xml.

Then I tried to make a test crash but it didn't appear neither in Firebase not Fabric dashboard, however I got a success log in logcat: Crashlytics report upload complete: <ID>.

When I sniffed the network, it appeared that I'm getting 403 Unathorized from Crashlytics. However when I add the Fabric API key in <meta-data/> tag it works and I see the crash report.

Help me please what is wrong with my configuration, why do I need to use old Fabric API key if I'm using new Firebase Crashlytics and docs don't state that.

Sukkoth answered 24/7, 2018 at 11:22 Comment(8)
Mike from Firebase here. Did you select that this app was new to Crashlytics or an existing Crashlytics app when setting things up?Camarena
@MikeBonnell I've selected that it was an existing Crashlytics app, and then after few minutes all reports from Fabric became visible on FirebaseSukkoth
Great, if it's an app that has already used Crashlytics from Fabric, then you should select that option.Camarena
@MikeBonnell I did it when setting up the sdk initially, however despite reports are showing in firebase console, it's not working without Fabric API keySukkoth
If you select that it's an existing Crashlytics app, then we expect the Fabric API key to be present.Camarena
@MikeBonnell oh ok, it's clear now. Thank youSukkoth
@MikeBonnell Thanks for the solution, But I am bit confused about this. There is this document when upgrading to firebase from fabric - firebase.google.com/docs/crashlytics/… So here it is specifically states that one has to remove the Fabric key from manifest. I also mailed to firebase support team but didn't get any reply.Vogt
@MikeBonnell We are using fabric.properties file to add the required secrets though after migrating to Firebase, we are not seeing any crashes reported from our latest playstore updates. Thoughts ?Siphonostele
B
6

For those on iOS that used Fabric, so this is what I finally got from support. I wanted to start fresh.

  • Visit https://firebase.google.com/docs/crashlytics/get-started?authuser=1#ios.
    • Revise pods in Podfile accordingly (specify versions of Fabric and Crashlytics as instructed)
    • Update the build phase run script: "${PODS_ROOT}/Fabric/run" instead of the current one that points to their Fabric API key
  • Remove API key from Info.plist - In your AppDelegate.swift, remove import Fabric and import Crashlytics and any Fabric.with statement, keep import Firebase and use FirebaseApp.configure() instead

  • Go to project settings in Firebase console, click the Integrations tab, unlink the appropriate Fabric app from Firebase (if you don't do this, you will get an error looking like: "[Fabric] failed to download settings Error Domain=FABNetworkError Code=-5")

  • Go to the Crashlytics tab and you should see that you have to onboard Firebase Crashlytics again.
  • Go through those steps choosing "This app doesn't have Crashlytics installed" and when you get to the final step, build and run the app and wait a few seconds. Then you Crashlytics tab will be setup.

Once I did this, and force crashed, it FINALLY showed up.

Behemoth answered 8/2, 2019 at 19:3 Comment(2)
Removing the API key from the plist is the key. Thanks for posting the answer.Henrik
After searching for days , unlink Fabric from Firebase finally solved my ios problem. thanksSuckow
E
3

Below things are mandatory, if you Migrate from existing Fabric crashlytic application to Firebase crashlytic

<meta-data
          android:name="io.fabric.ApiKey"
            android:value="xxxxxxxxxxxxxxxxxxxxxxxxxx"
            />
 Fabric.with(new Crashlytics()));

But not sure what will happen to these API and KEY, once fabric is down Say mid 2019.

Enforce answered 14/12, 2018 at 10:48 Comment(1)
That's correct, the new documentation says that you shouldn't change your Crashlytics/Fabric setup in the project when migrating. Adding Firebase services on top of that is OK. It seems we'll need to check for updates and do the actual Crashlytics migration once the new SDKs are available.Journalism
A
0

The Firebase Crash Reporting will be superseded by Fabric Crashlytics and not the other way around ...currently there still seems to be some dependency to firebase-crash, which might get removed in future versions.

https://firebase.google.com/docs/crashlytics/upgrade-from-crash-reporting

^ despite it reads "Firebase Crashlytics" there, it might still be "Fabric Crashlytics".

Atlee answered 28/7, 2018 at 12:59 Comment(2)
I guess it turned out to be the other way around for sure!Phore
@Phore Back then it seemed alike... as if.Atlee

© 2022 - 2024 — McMap. All rights reserved.