Open HarrisonShort opened 3 years ago
@HarrisonShort
Just to clarify: Are you trying to build standalone Mac desktop application using Firebase SDK?
I believe this is related to the persistent storage in Auth. On Mac, the login status and tokens are stored in keychain named
<your-package-name>.firebase.auth/<name-of-FirebaseApp>
That is, given that your package name
and FirebaseApp
is not changed for your two versions, they will be stored with the same name in keychain. The second instance will not be able to access the keychain and therefore cause the error.
Unfortunately, this is not a supported scenario for Firebase desktop implementation now. We only expect one instance per desktop, primarily to support running in Unity editor. See also #928. This is a different issue but not supported currently.
May I understand your use case to launch two instances on the same desktop? As I said, as long as either package name
or FirebaseApp
name is different, Auth API should store the persistent data in different key name.
package name
on the desktop should be the same to the app name you set in Firebase console.__FIRAPP_DEFAULT
I will change this to a feature request. Let me know if the workaround works for your case.
Shawn
@chkuang-g
Yes, we have a companion program to our main Android and iOS app that runs on standalone desktop platforms.
Thanks for getting back to us on this. For more clarification, we are not attempting to run two instances at the same time, but because we provide a direct download to the standalone Mac program it is possible for users to have two different builds of the same app on their computers (especially in the case that we push an update). When one is named differently to the other, the second instance will throw these errors.
All things considered, this is quite a specific edge case and we understand that it is unlikely to receive much attention since it doesn't effectively break anything. I will try the workaround and report back.
Thanks again. (:
[REQUIRED] Please fill in the following fields:
[REQUIRED] Please describe the issue here:
Having multiple builds on the one Mac with different names causes SaveUserData and DeleteUserData keychain errors. It seems as if the delete error appears once, followed by the adding error, and then the deleting error once more.
While this appears to mostly only be an issue for our dev team, we just want to find out whether there is anything we can do about it, as theoretically it could happen to end-users. Our builds are distributed through direct website downloads, rather than the Mac App Store, which means in the unlikely event that someone keeps an old build and renames it to something, this may occur.
Steps to reproduce: