0

Im logging non crash events on firebase crashlytics and apply some filters to get one specific device. And result is saying i have 6 events on chart and below on detail events it only show 2. What im doing wrong?

enter image description here

user1851366
  • 256
  • 6
  • 20
  • 41
  • Are you sure you didn't press before a few times? I tried to simulate the exact same thing and I got exactly 6 events. What exactly are those 6 non-fatal events? Can you please edit your question and show us the results? – Alex Mamo Aug 21 '21 at 12:17
  • Is just a message to make some kind of logs. And no, i didnt pressed before x times – user1851366 Aug 21 '21 at 13:44
  • I want to know what kind of logs are, so I can try to simulate again. – Alex Mamo Aug 21 '21 at 14:06
  • FirebaseCrashlytics.getInstance().recordException(new Exception("hello world)); – user1851366 Aug 21 '21 at 14:12
  • I tried to simulate in all ways and it works fine. Can you please provide a small video of how you actually create the filtering and how you get those results? – Alex Mamo Aug 22 '21 at 09:31

2 Answers2

0

You need to post your code... but without seeing your code, if you are using Thread.setDefaultUncaughtExceptionHandler(), Crashlytics.logException(e) or setDefaultUncaughtExceptionHandler(), etc. try removing setDefaultUncaughtExceptionHandler(). The recent updates have made some compatibility issues.. or if you don't have anything... trying playing around with this, it should update correctly.


@Override
public void uncaughtException(Thread thread, Throwable e) {
    e.printStackTrace();

    Crashlytics.logException(e);

    Utils.closeApplicationAndRestart(context, 5000, MainActivity.class);
}

Another option is to handle it as custom exception... and ensure you update the data correctly.

Transformer
  • 6,963
  • 2
  • 26
  • 52
0

The logs are recorded based on the events but their counts depends upon the number of events and number of occurrence.

counts = number of events * number of occurrence

It looks like the same events occurred again and again on the same device that causes the count of events is increased, but still the events are same.

In your case may be that two events occurred for three time that leads to the count as six.

halfer
  • 19,824
  • 17
  • 99
  • 186