Skip to content

[Bug] java.lang.IllegalStateException UnityPlayerGameActivity FirebaseApp was deleted #1156

@UnwindGamesDeveloper

Description

@UnwindGamesDeveloper

Description

Game Crashes at Launch some times.

Reproducing the issue

  • Add the Firebase Unity SDK.
  • Instantiate Firebase via FirebaseApp.Create instead of default instance.
  • Remove FirebaseInitProvider from manifest --- provider android:name="com.google.firebase.provider.FirebaseInitProvider" android:authorities="xyz.firebaseinitprovider" tools:node="remove"

Firebase Unity SDK Version

12.4.1

Unity editor version

6000.0.27f1

Installation Method

.unitypackage

Problematic Firebase Component(s)

No response

Other Firebase Component(s) in use

No response

Additional SDKs you are using

No response

Targeted Platform(s)

Android

Unity editor platform

Mac

Scripting Runtime

IL2CPP

Release Distribution Type

Pre-built SDK from https://firebase.google.com/download/unity

Relevant Log Output

java.lang.IllegalStateException: FirebaseApp was deleted
        at com.google.android.gms.common.internal.Preconditions.checkState(com.google.android.gms:play-services-basement@@18.3.0:2)
        at com.google.firebase.FirebaseApp.checkNotDeleted(FirebaseApp.java:462)
        at com.google.firebase.FirebaseApp.getApplicationContext(FirebaseApp.java:122)
        at com.google.firebase.installations.FirebaseInstallations.getPrefsWithGeneratedIdMultiProcessSafe(FirebaseInstallations.java:475)
        at com.google.firebase.installations.FirebaseInstallations.doRegistrationOrRefresh(FirebaseInstallations.java:361)
        at com.google.firebase.installations.FirebaseInstallations.lambda$getToken$2$com-google-firebase-installations-FirebaseInstallations(FirebaseInstallations.java:261)
        at com.google.firebase.installations.FirebaseInstallations$$ExternalSyntheticLambda4.run(D8$$SyntheticClass)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
        at com.google.firebase.concurrent.CustomThreadFactory.lambda$newThread$0$com-google-firebase-concurrent-CustomThreadFactory(CustomThreadFactory.java:47)
        at com.google.firebase.concurrent.CustomThreadFactory$$ExternalSyntheticLambda0.run(D8$$SyntheticClass)
        at java.lang.Thread.run(Thread.java:923)

If using CocoaPods for Apple platforms, the project's Podfile.lock

Expand Podfile.lock snippet
👀 Replace this line with the contents of your Podfile.lock!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions