question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Crashlytics fails to track app startup crashes

See original GitHub issue

Describe your environment

  • Android Studio version: 2020.3.1 patch 4
  • Firebase Component: Crashlytics
  • Component version: 17.4.1

Describe the problem

Crashlytics’ uncaught exception handler is printing TimeoutException when tracking crashes that happen in Application.onCreate().

FirebaseCrashlytics  E  Error handling uncaught exception
FirebaseCrashlytics  E  java.util.concurrent.TimeoutException
FirebaseCrashlytics  E      at t8.h0.a(Utils.java:11)
FirebaseCrashlytics  E      at t8.j.G(CrashlyticsController.java:6)
FirebaseCrashlytics  E      at t8.j$b.a(CrashlyticsController.java:1)
FirebaseCrashlytics  E      at t8.p.uncaughtException(CrashlyticsUncaughtExceptionHandler.java:4)
FirebaseCrashlytics  E      at io.sentry.UncaughtExceptionHandlerIntegration.uncaughtException(UncaughtExceptionHandlerIntegration.java:19)
FirebaseCrashlytics  E      at java.lang.ThreadGroup.uncaughtException(ThreadGroup.java:1073)
FirebaseCrashlytics  E      at java.lang.ThreadGroup.uncaughtException(ThreadGroup.java:1068)
FirebaseCrashlytics  E      at java.lang.Thread.dispatchUncaughtException(Thread.java:2200)

Steps to reproduce:

  1. Integrate Firebase Crashlytics with auto initialisation.
  2. Create a custom Application class and throw an exception from there.

Expected: Crashlytics should track crashes that happen in Application class Actual: Crashlytics fails to track crashes that happen in Application class and logs a TimeoutException in that process

Other information: We also use Sentry for crash reporting and it seems to track these crashes just fine

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:3
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
argzdevcommented, Feb 21, 2022

Thanks for the report, @vibin. Upon reproducing this on version 18.2.8, I also did not receive a crash report on Crashlytics dashboard when the exception happens in the Application class. A minor difference with that, I did not receive a TimeoutException, rather a RuntimeException.

Relevant Code:

public class CustomApplication extends Application {
    @Override
    public void onCreate() {
        super.onCreate();
        throw new RuntimeException("Test Crash");
    }
}

With that said, I’ll notify an engineer and see if what we can do here.

1reaction
mrichardscommented, Sep 2, 2022

We believe this was fixed in Crashlytics v18.2.3. Anyone experiencing this issue should update to the latest SDK version using the Firebase BoM (currently BoM v30.4.0). If the problem persists, please open a new GitHub issue. Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Crashlytics does not log app startup crashes #4176 - GitHub
Install a app version the crashes on App startUp, throw RuntimeException() in Application Class; Open the app, should crash the app. Open it ......
Read more >
Crashlytics troubleshooting and FAQ - Firebase
Crashes are poorly symbolicated. If your stack traces seem to be poorly symbolicated, check the following: If frames from your app's library lack...
Read more >
Firebase Crashlytics Crashing on App startup - Stack Overflow
There are two things you Omitted (1)in your project-level build.gradle file, add the Crashlytics Gradle plugin as a buildscript dependency.
Read more >
App crashes on startup, only for A… | Apple Developer Forums
I cannot replicate the problem that App Review team has with my app. In most cases Crashlytics doesn't even receive the crash.
Read more >
Android Question Crashlytics error at startup - B4X
The error isn't causing the app to crash, but I suspect it will be causing Crashlytics to not work. Here's the log:
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found