Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Failed to retrieve settings from https://settings.crashlytics.com/spi/v2/platforms/android/apps/

I am trying out the new Firebase/Crashlytics setup and seem to run into a weird issue.

  • I have one Android code base with multiple product flavors and each flavor is a separate individual app.
  • all of these apps are registered in Fabric (from the past)
  • all of these apps are added in Firebase
  • All linking between the two seems ok (from Fabric side as well as from Firebase side, it says that it is all linked up)
  • I removed the Fabric API key from the manifest file and added the appropriate plugins/dependencies etc. to both gradle files

I try to send a test crash report as per Firebase instructions.

  1. I receive it perfectly fine on one of the product flavors, so I assume all works well. However,
  2. the rest of the product flavors do not send the crash report and I get this error in log:

E/Fabric: Failed to retrieve settings from https://settings.crashlytics.com/spi/v2/platforms/android/apps/package name/settings

like image 994
Kenneth Browning Avatar asked Mar 09 '18 10:03

Kenneth Browning


People also ask

What is firebase settings Crashlytics com?

Firebase Crashlytics is a lightweight, realtime crash reporter that helps you track, prioritize, and fix stability issues that erode your app quality. Crashlytics saves you troubleshooting time by intelligently grouping crashes and highlighting the circumstances that lead up to them.

How does Crashlytics work in Android?

Crashlytics creates a exception handler that intercepts the exceptions that weren't caught and does something with them but it also sends the exception to the previous exception handler, that's why the app stills crashes.


2 Answers

Ok, I think I solved the problem, but the solution does not seem to be the way it should work (at least I do not think).

  • Go to Firebase Console > Project Settings > Account Linking > Fabric > Select the app and Unlink it
  • Confim in Fabric > App > Firebase - that it is unlinked
  • Go to Firebase > Project > Crashlytics (select the app you want) and you should now get a dialog to link your app again
  • Choose to link as a New Crashlytics (not existing one) and follow the directions
  • After that all should work fine

So basically, from Fabric>Firebase screen - there is no link visible and from Firebase>Account Linking>Fabric screen - there is also no linking visible. So no linking, but your crashes will be visible in Firebase.

like image 104
Kenneth Browning Avatar answered Sep 23 '22 10:09

Kenneth Browning


This takes me a lot of time than I figured out how to migrate correctly. Actually you have two ways how to do it:

  1. Perform clean migration without keeping crash history from Fabric Crashlytics

    This way is described in Firebase Crashlytics developer guide. You have to here remove com.crashlytics.ApiKey meta-data from app manifest file.

    With this way you must not link Fabric with Firebase otherwise crashes will not shown in Firebase nor Fabric console.

  2. Link Fabric with Firebase and keep the crash history

    This way is probably nowhere documented. Crucial is here to keep com.crashlytics.ApiKey meta-data in your manifest. Then you need to link Fabric Crashlytics with Firebase. You can also enable forwarding Events (formerly Answers) to Firebase Analytics. Both actions are presented in Fabric console, look for Firebase in a side menu.

    All new crash reports show up in both Fabric console and Firebase console. Also this linking arrange a copying all Fabric crash report history to Firebase.

    I think firebase-core artifact is not necessary here, but I added it. I'm also using Fabric Events, so with firebase-core additional app usage events was appeared in Firebase Analytics.

like image 38
Arcao Avatar answered Sep 23 '22 10:09

Arcao