Flutterfire: [firebase_crashlytics] Either the Crashlytics plugin doesn't work, or the instruction is wrong

Created on 13 Oct 2019  ยท  31Comments  ยท  Source: FirebaseExtended/flutterfire

I followed the setup instruction from Pub: https://pub.dartlang.org/packages/firebase_crashlytics

I also enabled debug logging: https://firebase.google.com/docs/crashlytics/force-a-crash

Crashlytics seems to be running when my app is started:

04-11 19:48:09.800  5815  5815 D Fabric  : Falling back to Crashlytics key lookup from Manifest
04-11 19:48:09.801  5815  5815 D Fabric  : Falling back to Crashlytics key lookup from Strings
04-11 19:48:09.836  5815  5863 D Fabric  : Falling back to Crashlytics key lookup from Manifest
04-11 19:48:09.836  5815  5863 D Fabric  : Falling back to Crashlytics key lookup from Strings
04-11 19:48:09.836  5815  5863 D Fabric  : Generating Crashlytics ApiKey from google_app_id in Strings
04-11 19:48:09.847  5815  5873 D Fabric  : Using AdvertisingInfo from Preference Store
04-11 19:48:09.850  5815  5815 D Fabric  : Falling back to Crashlytics key lookup from Manifest
04-11 19:48:09.850  5815  5815 D Fabric  : Falling back to Crashlytics key lookup from Strings
04-11 19:48:09.852  5815  5815 D Fabric  : Falling back to Crashlytics key lookup from Manifest
04-11 19:48:09.852  5815  5863 D Fabric  : Build ID is: 597ad0fd-xxxx-xxxx-xxxx-cc4204e14e50
04-11 19:48:09.852  5815  5815 D Fabric  : Falling back to Crashlytics key lookup from Strings
04-11 19:48:09.852  5815  5815 D Fabric  : Generating Crashlytics ApiKey from google_app_id in Strings
04-11 19:48:09.852  5815  5815 D Fabric  : Build ID is: 597ad0fd-xxxx-xxxx-xxxx-cc4204e14e50
04-11 19:48:09.853  5815  5815 I CrashlyticsCore: Initializing Crashlytics 2.6.8.32
04-11 19:48:09.855  5815  5873 D Fabric  : Falling back to Crashlytics key lookup from Manifest
04-11 19:48:09.856  5815  5873 D Fabric  : Falling back to Crashlytics key lookup from Strings
04-11 19:48:09.858  5815  5873 D Fabric  : Build ID is: 597ad0fd-xxxx-xxxx-xxxx-cc4204e14e50
04-11 19:48:09.859  5815  5815 D CrashlyticsCore: Installer package name is: null
04-11 19:48:09.865  5815  5863 D Fabric  : Build ID is: 597ad0fd-xxxx-xxxx-xxxx-cc4204e14e50
04-11 19:48:09.882  5815  5815 D Fabric  : Falling back to Crashlytics key lookup from Manifest
04-11 19:48:09.882  5815  5815 D Fabric  : Falling back to Crashlytics key lookup from Strings
04-11 19:48:09.883  5815  5815 D CrashlyticsCore: Exception handling initialization successful
04-11 19:48:09.883  5815  5815 D Fabric  : Initializing io.fabric.sdk.android:fabric [Version: 1.4.8.32], with the following kits:
04-11 19:48:09.883  5815  5815 D Fabric  : com.crashlytics.sdk.android:crashlytics [Version: 2.9.9.32]
04-11 19:48:09.883  5815  5815 D Fabric  : com.crashlytics.sdk.android:beta [Version: 1.2.10.27]
04-11 19:48:09.883  5815  5815 D Fabric  : com.crashlytics.sdk.android:answers [Version: 1.4.7.32]
04-11 19:48:09.883  5815  5815 D Fabric  : com.crashlytics.sdk.android.crashlytics-core [Version: 2.6.8.32]
04-11 19:48:09.883  5815  5815 D Fabric  :
04-11 19:48:09.884  5815  5863 D Fabric  : Requesting settings from https://settings.crashlytics.com/spi/v2/platforms/android/apps/com.myapp/settings
04-11 19:48:09.884  5815  5863 D Fabric  : Settings query params were: {instance=61ebeb4d13cce55a1f3a99f42e32b65ca2b2xxxx, build_version=1, display_version=0.0.1, source=1, icon_hash=204b9a3f51a1102e42ef65e3a6c4f8cda2ebxxxx}
04-11 19:48:09.885  5815  5879 D CrashlyticsCore: Opening a new session with ID 5CAF29790373-0001-16B7-47070E28DA82
04-11 19:48:10.625  5815  5875 D Fabric  : Using AdvertisingInfo from Reflection Provider
04-11 19:48:11.309  5815  5863 D Fabric  : Settings result was: 200
04-11 19:48:11.314  5815  5863 D Fabric  : Settings request ID: affca8bcac5aee10b1b37bf2a6cb00f6
04-11 19:48:11.315  5815  5863 D Fabric  : Writing settings to cache file...
04-11 19:48:11.320  5815  5863 D Fabric  : Loaded settings: {"settings_version":2,"cache_duration":7200,"features":{"collect_logged_exceptions":true,"collect_reports":true,"collect_analytics":true,"prompt_enabled":false,"push_enabled":true,"firebase_crashlytics_enabled":true},"analytics":{"url":"https:\/\/e.crashlytics.com\/spi\/v2\/events","flush_interval_secs":120,"max_file_count_per_send":1,"track_custom_events":true,"track_predefined_events":true,"track_view_controllers":false,"flush_on_background":true,"max_byte_size_per_file":40000,"max_pending_send_file_count":20,"sampling_rate":1,"forward_to_google_analytics":false,"include_purchase_events_in_forwarded_events":false},"beta":{"update_suspend_duration":1209600,"update_endpoint":""},"app":{"identifier":"com.myapp","status":"activated","url":"https:\/\/api.crashlytics.com\/spi\/v1\/platforms\/android\/apps\/com.myapp","reports_url":"https:\/\/reports.crashlytics.com\/spi\/v1\/platforms\/android\/apps\/com.myapp\/reports","ndk_reports_url":"https:\/\/reports.crashlytics.com\/sdk-api\/v1\/platforms\/android\/apps\/com.myapp\/minidumps","update_required":true},"session":{"log_buffer_size":64000,"max_chained_exception_depth":16,"max_complete_sessions_count":4,"max_custom_exception_events":8,"max_custom_key_value_pairs":64,"identifier_mask":255},"prompt":{"title":"Send Crash Report?","message":"Looks like we crashed! Please help us fix the problem by sending a crash report.","send_button_title":"Send","show_cancel_button":true,"cancel_button_title":"Don't Send","show_always_send_button":true,"always_send_button_title":"Always Send"},"expires_at":1554990491315}
04-11 19:48:11.322  5815  5863 D Fabric  : Build ID is: 597ad0fd-xxxx-xxxx-xxxx-cc4204e14e50
04-11 19:48:11.323  5815  5863 D Fabric  : Server says an update is required - forcing a full App update.
04-11 19:48:11.324  5815  5863 D Fabric  : App icon resource ID is 213136xxxx
04-11 19:48:11.326  5815  5863 D Fabric  : Falling back to Crashlytics key lookup from Manifest
04-11 19:48:11.326  5815  5863 D Fabric  : Falling back to Crashlytics key lookup from Strings
04-11 19:48:11.326  5815  5863 D Fabric  : Generating Crashlytics ApiKey from google_app_id in Strings
04-11 19:48:11.327  5815  5863 D Fabric  : Build ID is: 597ad0fd-xxxx-xxxx-xxxx-cc4204e14e50
04-11 19:48:12.193  5815  5863 D Fabric  : Sending app info to https://api.crashlytics.com/spi/v1/platforms/android/apps/com.myapp
04-11 19:48:12.194  5815  5863 D Fabric  : App icon hash is 204b9a3f51a1102e42ef65e3a6c4f8cda2ebxxxx
04-11 19:48:12.194  5815  5863 D Fabric  : App icon size is 192x192
04-11 19:48:12.968  5815  5863 D Fabric  : Update app request ID: 8310b867f89166622217f661de62xxxx
04-11 19:48:12.968  5815  5863 D Fabric  : Result was 204
04-11 19:48:12.973  5815  5879 D CrashlyticsCore: Initialization marker file created.
04-11 19:48:12.976  5815  5873 D Fabric  : Falling back to Crashlytics key lookup from Manifest
04-11 19:48:12.977  5815  5873 D Fabric  : Falling back to Crashlytics key lookup from Strings
04-11 19:48:12.977  5815  5873 D Fabric  : Generating Crashlytics ApiKey from google_app_id in Strings
04-11 19:48:12.984  5815  5869 D CrashlyticsCore: Registered Firebase Analytics event listener for breadcrumbs: true
04-11 19:48:12.986  5815  5879 D CrashlyticsCore: Finalizing previously open sessions.
04-11 19:48:12.993  5815  5879 D CrashlyticsCore: Closing open sessions.
04-11 19:48:12.994  5815  5879 D CrashlyticsCore: Closing session: 5CAF28E302B3-XXXX-YYYY-47070E28DA82
04-11 19:48:12.994  5815  5879 D CrashlyticsCore: Collecting session parts for ID 5CAF28E302B3-XXXX-YYYY-47070E28DA82
04-11 19:48:12.994  5815  5879 D CrashlyticsCore: Session 5CAF28E302B3-XXXX-YYYY-47070E28DA82 has fatal exception: false
04-11 19:48:12.995  5815  5879 D CrashlyticsCore: Session 5CAF28E302B3-XXXX-YYYY-47070E28DA82 has non-fatal exceptions: false
04-11 19:48:12.995  5815  5879 D CrashlyticsCore: No events present for session ID 5CAF28E302B3-XXXX-YYYY-47070E28DA82
04-11 19:48:12.997  5815  5879 D CrashlyticsCore: Removing session part files for ID 5CAF28E302B3-XXXX-YYYY-47070E28DA82
04-11 19:48:13.008  5815  5879 D CrashlyticsCore: Closed all previously open sessions
04-11 19:48:13.018  5815  5879 D CrashlyticsCore: Initialization marker file removed: true
04-11 19:48:13.018  5815  5973 D CrashlyticsCore: Starting report processing in 1.0 second(s)...
04-11 19:48:14.057  5815  5973 D CrashlyticsCore: Checking for crash reports...
04-11 19:48:14.059  5815  5973 D CrashlyticsCore: No reports found.

And, according to https://github.com/flutter/plugins/blob/master/packages/firebase_crashlytics/example/lib/main.dart I can verify by manually throwing error:

throw StateError('Uncaught error thrown by app.');

(I've set enableInDevMode to true as well).

The error is indeed thrown, as shown in Android Studio "Run" panel:

E/flutter ( 5815): [ERROR:flutter/lib/ui/ui_dart_state.cc(148)] Unhandled Exception: Bad state: Uncaught error thrown by app.
E/flutter ( 5815): #0      SettingsRoute._login (package:app/routes/SettingsRoute.dart:61:3)
E/flutter ( 5815): <asynchronous suspension>
E/flutter ( 5815): #1      SettingsRoute.build.<anonymous closure> (package:app/routes/SettingsRoute.dart:47:32)
E/flutter ( 5815): #2      _InkResponseState._handleTap (package:flutter/src/material/ink_well.dart:511:14)

But my dashboard ( https://console.firebase.google.com/u/0/project/MYPROJECT/crashlytics/app/android:com.myapp/issues?state=open&time=last-seven-days&type=all ) says my app is 100% error-free.

And ABD log doesn't show anything.

What did I miss?

EDIT: Flutter doctor result:

[โœ“] Flutter (Channel master, v1.4.11-pre.12, on Mac OS X 10.13.6 17G5019, locale en-XX)
    โ€ข Flutter version 1.4.11-pre.12 at /java/flutter
    โ€ข Framework revision 5e52f5df55 (6 days ago), 2019-04-04 22:48:45 -0400
    โ€ข Engine revision 697e541a8d
    โ€ข Dart version 2.2.1 (build 2.2.1-dev.3.0 None)

[โœ“] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
    โ€ข Android SDK at /java/android
    โ€ข Android NDK location not configured (optional; useful for native profiling support)
    โ€ข Platform android-28, build-tools 28.0.3
    โ€ข ANDROID_HOME = /java/android
    โ€ข Java binary at: /Applications/Development/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    โ€ข Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1248-b01)
    โ€ข All Android licenses accepted.

[โœ“] iOS toolchain - develop for iOS devices (Xcode 10.1)
    โ€ข Xcode at /Applications/Xcode.app/Contents/Developer
    โ€ข Xcode 10.1, Build version 10B61
    โ€ข ios-deploy 2.0.0
    โ€ข CocoaPods version 1.5.3

[โœ“] Android Studio (version 3.3)
    โ€ข Android Studio at /Applications/Development/Android Studio.app/Contents
    โ€ข Flutter plugin version 34.0.1
    โ€ข Dart plugin version 182.5215
    โ€ข Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1248-b01)

[โœ“] Connected device (1 available)
    โ€ข Pixel 2 XL โ€ข 709KPRW0070366 โ€ข android-arm64 โ€ข Android 9 (API 28)
crowd crashlytics bug documentation

Most helpful comment

Having the same issue even with a really simple app:

```dart
void main() {
Crashlytics.instance.enableInDevMode = true;
FlutterError.onError = Crashlytics.instance.recordFlutterError;
runApp(MyApp());
}

class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Test',
home: Scaffold(
appBar: AppBar(
title: Text('Test'),
),
floatingActionButton: FloatingActionButton(
onPressed: () => Crashlytics.instance.crash(),
child: Icon(Icons.error),
),
),
);
}
}

All 31 comments

@wiradikusuma

The issue at https://github.com/flutter/flutter/issues/30913 has been closed and moved here. Future collaboration on this issue will be done here.

Having the same issue even with a really simple app:

```dart
void main() {
Crashlytics.instance.enableInDevMode = true;
FlutterError.onError = Crashlytics.instance.recordFlutterError;
runApp(MyApp());
}

class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Test',
home: Scaffold(
appBar: AppBar(
title: Text('Test'),
),
floatingActionButton: FloatingActionButton(
onPressed: () => Crashlytics.instance.crash(),
child: Icon(Icons.error),
),
),
);
}
}

I'm wondering if this is related to a previous issue with Crashlytics plugin:
https://github.com/FirebaseExtended/flutterfire/issues/1149

Please try a couple of things:

  1. If you are using an IDE the error may be caught before it gets to the Crashlytics plugin and thus not reported. To avoid this run the app directly using flutter run and see if the error is reported then.

  2. Errors are only reported on app restart. So please look out for the reported log statement on app restart.

  3. Are you seeing this with the Crashlytics plugin example app?

The default filter in the Crashlytics page is for fatal failures, but I believe that the function Crashanalytics.instance.crash() does not produce a fatal error, and thus being categorized as a not fatal error.

Have you tried removing the default filter or the Crashlytics page, which will only show fatal errors?

Also check: https://stackoverflow.com/a/57637124/10403944

Another thing that could be happening is that the iOS Simulator doesn't allow Crashlytics to process crash reports. If you run the app, then stop it, then execute the crash, and then finally run it again, you'll see the crash on the Crashlytics page.

Also check: https://docs.fabric.io/apple/crashlytics/test-crash.html#troubleshooting and https://stackoverflow.com/a/20286446/10403944

@kroikie is it my impression or all Flutter crashes are not being processed as Fatal Exceptions by Crashlytics, so they are only reported if the user restarts the application, in opposition with the native Android behavior, whereas Fatal Exceptions are communicated right away and Non-Fatal only after a restart?

I can't record any Crashlytics event using emulator, just work in real devices. This is the correct behavior expected?

Try to restart the app, it uploads on app restarts... But it takes a while to appear on the crashlytics dashboard

I restarted multiples times and cleaned the build folder. The records using crashlytics in emulator happen a week ago, but just the records in the real devices are registered. I think this behavior is correlated https://github.com/FirebaseExtended/flutterfire/issues/1413 issue.

Well, it works on my AVD, can't help you more than that.

after some digging on this, make sure you understand how crashlytics works. Specifically, crashlytics does not send errors to firebase when an error occurs. Specifically, it sends errors to firebase the next time you start the app. So you must force the app to entirely stop and restart before anything will showup on firebase. Hot reload doesn't count.

I can't get it to work for iOS, see full description of the issue here.
StackOverflow #60111182

Someone who got it to work for iOS?

I can't get it to work on iOS too.

Following this thread regading the issue:

https://github.com/FirebaseExtended/flutterfire/issues/1951

@kroikie Have you ever personally tested the instructions? I have several time on several projects and they do not work, which is the title of this issue.

Tracking the Crashlytics not working issues here ๐Ÿ‘

I have everything setup as per instructions, but no errors (non-fatal, fatal, etc) are showing in crashlytics portal even though console output crashlytics says it's reporting issues. Crashlyitics has been in app for weeks, and none of the errors show - particularly non-fatals which with flutter are what we care about.

With all the comments saying it doesn't work, I figured I'd re-confirm that my crashlytics is working for both android and ios on flutter using the Crashlytics.instance.crash() to test. All I did was follow the instructions. The only things that caught be during the initial setup/testing was that you have to make sure you restart the app after a crash (restart, not reinstall, and not hot-reload). Also make sure you setup your firebase properly : https://firebase.google.com/docs/crashlytics, you have to get past the point where firebase recognises your app before crashlytics works (I don't remember the exact spot right now, but there's a point where firebase console sits there waiting for a signal from your app. If you can't get past that verification point, firebase won't work).

@r6squeegee I agree it works .... sometimes for some reason.

I have two apps for which it works fine. But comparing the setup steps and my notes and the formal instructions, I cannot seem to get it to work for newer projects for some reason.

But that is the point of this particular issue .... there is a step, that is not specified here:

https://pub.dev/packages/firebase_crashlytics

or here:

https://firebase.google.com/docs/crashlytics

That seems to determine if one project works and another does not.

Open the iOS project in Xcode and add the command line argument -FIRAnalyticsDebugEnabled and then run the iOS project in using Xcode to see if the Crashlytics is working

To enable Analytics debugging output in Xcode console:

  • In Xcode, select Product > Scheme > Edit scheme...
  • Select Run from the left menu.
  • Select the Arguments tab.
  • In the Arguments Passed On Launch section, add -FIRAnalyticsDebugEnabled.

This is not included when running the project with flutter run so this way you will know if Crashlytics is working

@workerbee22 So it used to work, but dosn't work for new project?
@ajackson2907 When I tried it some time ago I saw this in the log:

[DEVICE LOG] 2020-03-10 23:07:53.920251+0100 localhost Runner[33863]: (Flutter) flutter: โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ• โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ• [ +1 ms] flutter: #13 GestureBinding._handlePointerDataPacket (package:flutter/src/gestures/binding.dart:86:7) [ ] flutter: #17 _invoke1 (dart:ui/hooks.dart:273:10) [ ] flutter: #18 _dispatchPointerDataPacket (dart:ui/hooks.dart:182:5) [ ] flutter: (elided 3 frames from package dart:async) [ ] flutter: [ ] flutter: Handler: "onTap" [ ] flutter: Recognizer: [ ] flutter: TapGestureRecognizer#5a07c [ ] flutter: โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ• โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ• [ +66 ms] [DEVICE LOG] 2020-03-10 23:07:53.993246+0100 localhost Runner[33863]: (Flutter) flutter: firebase_crashlytics: Error reported to Crashlytics. [ ] flutter: firebase_crashlytics: Error reported to Crashlytics. [+3608 ms]

However, it never showed up in Firebase Console

IIRC there's one log thar says the error was recorded and another thar says the error was uploaded to Crashlytics. One happens when the exception occurs and the other only when you restart the App. The language on those logs is misleading, I don't remember it exactly but maybe that "reported" is just the "recorded and not yet uploaded", be sure to restart your app to test it: close the app and open it again as a user will do, not in the IDE.

I have tested that as well whitout any informatino showing in Firebase Console.
Is there someone who has it working on iOS with the newest version?

I have just made it work. What I did:

  1. Followed https://pub.dev/packages/firebase_crashlytics, including the step to add the plist for Xcode 10, even though I'm on 11.x.
  2. In my Firebase console, I opened the Crashlytics section and chose 'Add SDK' for both Android and iOS (you need to use the combo box to switch to the other one).
  3. Tested it on the devices. Crashes from both Android and iOS appear almost instantaneously.
  4. Make sure to remove the default 'Crash' filters (Event type = "Crashes"). Flutter issues are apparently "Non-fatals".

It cost me half a day. I first tested it on Android and enabled the SDK, as Android was the one chosen by default for me. Took me a lot of time to figure out that the filter was the culprit, but I could see the issues.

Then, as I was failing to make it work on iOS, after reading a lot of issues like this one, I clicked around in frustration, noticed the combo box in the Crashlytics section and noticed that I can click the 'Add SDK' button again for iOS. (For some reason I had assumed that if I enabled it once, it would work for both systems.) With this (and also disabling the crash filter), I see my crashes. The only thing that isn't perfect I see the following in iOS logs:

[Fabric] [Fabric +with] called multiple times. Only the first call is honored, please pass all kits you wish to initialize

All in all, for me, 2. and especially 4. above were what I needed to do.

README doesn't mention the need to add GoogleServices file to project as a part of the setup. This will cause issues setting up the package if this is the first firebase-related package the dev uses.

I manage to get it to work today, I had missed that you need to add the SDK for iOS in Firebase Console.

Step 1: Set up Crashlytics in the Firebase console
Click Crashlytics in the left-hand nav panel of the Firebase console.

If your Firebase project has multiple apps registered in it, select the app you just added from the dropdown next to Crashlytics in the top bar of the console.

Click Add SDK.

https://firebase.google.com/docs/crashlytics/get-started

I'm wondering if this is related to a previous issue with Crashlytics plugin:

1149

Please try a couple of things:

  1. If you are using an IDE the error may be caught before it gets to the Crashlytics plugin and thus not reported. To avoid this run the app directly using flutter run and see if the error is reported then.
  2. Errors are only reported on app restart. So please look out for the reported log statement on app restart.
  3. Are you seeing this with the Crashlytics plugin example app?

2 hours into working this out steps 1 & 2 were what solved it for me - thanks for sharing!

Been stuck here for hours. Has anyone got it working ever?

  • Followed every single instruction from flutter_crashlytics package.
  • Checked build.gradle and app/build.gradle changes multiple times.
  • Tried running through IDE and even through flutter run but no difference.
  • Restarted application several times after invoking the crash but no difference.
  • Punched myself in the face but no difference. ๐Ÿ˜’

@iamporus Did you include the GoogleServices file in your projects? I'm almost certain this is an issue with the docs, which don't mention this step. This is usually not a problem if you're using a firebase service other than crashlytics. If this is the first firebase service you're setting up, you probably don't have the GoogleServices file like, for example, indicated in the docs for Android

@lautaropaske Sorry I forgot to mention.
I've firebase analytics integration in working condition which requires the json file.

  • I had enabled crashlytics from the firebase console,
  • downloaded the Google Services json file again (thought it would get updated once I enable crashlytics) and
  • pasted it in the project at app/ location.
  • made sure to call FirebaseApp.initialize() in async manner.
  • invoked a crash manually by calling FirebaseCrashlytics.instance.crash()

The result is still the same; the never ending spinning progress bar at firebase crashlytics console and Bad state: Uncaught error at flutter logs console.
Let me know if I've missed out on anything.

There's a little update. Without doing any changes whatsoever, my crashes (non-fatal) started magically appearing in the firebase console this morning. Last time I checked they weren't there ๐Ÿคจ. Looks like some sort of glitch at server end.

But manual crashes using FirebaseCrashlytics.instance.crash() still result in Bad state: Uncaught error and never get reported.

A new Crashlytics plugin has now landed on master which should solve this issue.

Checkout the migration guide to get started on upgrading to the new Crashlytics plugin: https://firebase.flutter.dev/docs/migration/

Was this page helpful?
0 / 5 - 0 ratings