firebase / quickstart-unity

Firebase Quickstart Samples for Unity
https://firebase.google.com/games
Apache License 2.0
835 stars 431 forks source link

App initializer installations not found, failed to enable. #1244

Closed WikyWu closed 2 years ago

WikyWu commented 2 years ago

[REQUIRED] Please fill in the following fields:

[REQUIRED] Please describe the question here:

Hello! Firebase components in use run correct, but when i use the installations, firebsae log print "Enable module 'installations' for 'Firebase.Installations.FirebaseInstallations, Firebase.Installations'" and "App initializer installations not found, failed to enable", thanks for your reply.

google-oss-bot commented 2 years ago

I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.

paulinon commented 2 years ago

Hi @WikyWu,

In order to identify the cause of this behavior, could you provide a minimal, reproducible example along with the complete steps to replicate the issue?

WikyWu commented 2 years ago

In order to identify the cause of this behavior, could you provide a minimal, reproducible example along with the complete steps to replicate the issue?

Hi@paulinon, in order to replicate the issue, i just create a empty unity project and import the installations.unitypackage, could i need to call some initiate method?

paulinon commented 2 years ago

Thanks for the additional information, @WikyWu. Did you remember to add the google-services.json file for your app in your Unity project? It's possible that this is the cause of your issue. After performing this step on my end, the initialization became successful.

WikyWu commented 2 years ago

Thanks for the additional information, @WikyWu. Did you remember to add the google-services.json file for your app in your Unity project? It's possible that this is the cause of your issue. After performing this step on my end, the initialization became successful.

Thanks for your attention. The json file i have put in the unity project, also i have added the SHA1 certificate fingerprint, unfortunately, the same log has printed.

paulinon commented 2 years ago

HI @WikyWu,

To be more specific, I was able to encounter logs saying that initialization was unsuccessful, but after a few seconds, new logs appeared saying that initialization was successful. Are you facing a similar behavior?

WikyWu commented 2 years ago

@paulinon, i print the all logs in the log.txt, hope it can be used. Thanks! log.txt

paulinon commented 2 years ago

Thanks for the additional information, @WikyWu. It's possible that one or more of your libraries were disabled or deleted from your project. Could you verify if your FirebaseCppInstallations.dll is present and has both Editor and Standalone selected? Additionally, are these logs the output of just having the Installations package in an empty Unity project?

WikyWu commented 2 years ago

Thanks for the additional information, @WikyWu. It's possible that one or more of your libraries were disabled or deleted from your project. Could you verify if your FirebaseCppInstallations.dll is present and has both Editor and Standalone selected? Additionally, are these logs the output of just having the Installations package in an empty Unity project?

Hi @paulinon, i just import the installations package in an empty unity project, both Editor and Standalone selected. . Thank you very much! 1648106304947

paulinon commented 2 years ago

Hi @WikyWu,

Could you try if updating the Unity editor makes a difference (latest LTS Release is version 2020.3.32f1)? If it doesn't, please share the steps you've taken in retrieving your logs.

WikyWu commented 2 years ago

please share the steps you've taken in retrieving your logs.

Hi @paulinon, i use the 2019.4.27.f1 LTS Release Unity editor to program, updating will cause much problem. The steps i have taken:

  1. Get the json file and put in unity asssets
  2. Import the Installations.unitypackage
  3. Android -> force resolve -> resolution succeed
  4. Call method FirebaseApp.LogLevel = LogLevel.Verbose and FirebaseApp.CheckAndFixDependenciesAsync().ContinueWith
  5. Run the unity project will get the logs
  6. Import android project- > tag:firebase -> also get the logs
paulinon commented 2 years ago

Thanks for the additional context, @WikyWu. I was able to replicate the issue you're facing using the steps you've listed. I'll let the team know about this, and you may refer to this thread for updates. For now, I'll be marking this as a bug.

WikyWu commented 2 years ago

Thanks for the additional context, @WikyWu. I was able to replicate the issue you're facing using the steps you've listed. I'll let the team know about this, and you may refer to this thread for updates. For now, I'll be marking this as a bug.

Thank you very much @paulinon , looking forward to your reply!

cynthiajoan commented 2 years ago

Hi @WikyWu, I'd like to check is there any functional affect to your app besides the log info?

WikyWu commented 2 years ago

Hello@cynthiajoan @paulinon, i just create an new firebase project and replace the json file and package name, surprised me that the project gets succeed result and i can get the installations token, but the log "App initializer installations not found, failed to enable" also printed, i am confused and don't know why.

WikyWu commented 2 years ago

Thank you very much! @cynthiajoan @paulinon