Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] firebase doesn't select app by package name #1061

Open
hoainam1593 opened this issue Jul 5, 2024 · 1 comment
Open

[Bug] firebase doesn't select app by package name #1061

hoainam1593 opened this issue Jul 5, 2024 · 1 comment

Comments

@hoainam1593
Copy link

Description

when google-services.json contains more than 1 app, firebase doesn't choose app base on package name, it always choose one of apps no matter what package name.

Reproducing the issue

  • create an empty firebase project
  • create 2 android apps with 2 different package name (1) and (2)
  • create an empty unity project with package name (1)
  • download google-services.json and place into unity project
  • log Debug.LogError(FirebaseApp.DefaultInstance.Options.AppId); in script
  • build apk (1)
  • change package name to (2)
  • build apk (2)
  • run apk (1) => logcat will show appId of app (1)
  • run apk (2) => logcat will show appId of app (1)

Firebase Unity SDK Version

12.1.0

Unity editor version

2022.3.17

Installation Method

Unity Package Manager

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

Windows

Scripting Runtime

Mono

Release Distribution Type

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

Relevant Log Output

No response

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!
@argzdev argzdev added api: core and removed new New issue. type: bug labels Jul 5, 2024
@argzdev argzdev self-assigned this Jul 5, 2024
@argzdev
Copy link

argzdev commented Jul 5, 2024

Thanks for reporting, @hoainam1593. I was able to reproduce the behavior. It looks like replacing the google-services.json will trigger to correct this behavior, but we shouldn't need to do so. That said, I'll go ahead and report this to our engineering team.

@argzdev argzdev removed their assignment Jul 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants