-
Notifications
You must be signed in to change notification settings - Fork 928
Multiple apps - Single SDK #6378
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
Comments
I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight. |
The same issue, while debugging mode. |
Thank you! I hadn't even gotten that far to realize that was the root cause. It appears debugging messes up firebase auth. |
Similar/same issue here: Firebase: Error thrown when reading from storage. Original error: (0, _idb.openDB) is not a function. (app/storage-get).
I use React native debugger v. 0.12.1 |
Hi @ericmager, thanks for the report. I was able to reproduce the behavior now. Let me check what we can do for this issue or bring someone here that can provide more context about it. I’ll update this thread if I have any information to share. |
This may be an error with the Metro bundler. Can you take a look at the possible workarounds suggested in #6253 and let us know if they work? |
Hey @ericmager. We need more information to resolve this issue but there hasn't been an update in 5 weekdays. I'm marking the issue as stale and if there are no new updates in the next 5 days I will close it automatically. If you have more information that will help us get to the bottom of this, just add a comment! |
Since there haven't been any recent updates here, I am going to close this issue. @ericmager if you're still experiencing this problem and want to continue the discussion just leave a comment here and we are happy to re-open this. |
Still having this problem, Is there any solution for that? |
I face this problem too. Only while debug mode. I can't to login into my app.
|
Eventually I used patch-package to change idb main file
It solves the problem instead of changing it threw metro.config.js file
…On Sat, 23 Jul 2022 at 1:42 i-in-range ***@***.***> wrote:
I face this problem too. Only while debug mode. I can't to login into my
app.
Possible Unhandled Promise Rejection (id: 2): FirebaseError: Firebase:
Error thrown when reading from storage. Original error: (0 , _idb.openDB)
is not a function. (app/storage-get).
—
Reply to this email directly, view it on GitHub
<#6378 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AXFSDQ52VNXJUGA7PW2QUV3VVMPW3ANCNFSM5ZRQZVQQ>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
I'm using expo to implement the js sdk for a react native ios app. We already have the website up and running and everything works fine. I've tried using the same app sdk (api key, app name, etc) in as in the website, and I've also tried creating a new web app in firebase. I continue to get the same error when I try to log in or access authenticated data:
Possible Unhandled Promise Rejection (id: 30):
FirebaseError: Firebase: Error thrown when reading from storage. Original error: (0 , _idb.openDB) is not a function. (app/storage-get).
FirebaseError: Firebase: Error thrown when reading from storage. Original error: (0 , _idb.openDB) is not a function. (app/storage-get).
at readHeartbeatsFromIndexedDB$ (http://10.151.5.106:19000/index.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:159841:33)
at tryCatch (http://10.151.5.106:19000/index.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:24626:19)
at Generator._invoke (http://10.151.5.106:19000/index.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:24606:26)
at Generator.next (http://10.151.5.106:19000/index.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:24657:23)
at tryCatch (http://10.151.5.106:19000/index.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:24626:19)
at invoke (http://10.151.5.106:19000/index.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:24664:22)
at http://10.151.5.106:19000/index.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:24688:13
at tryCallTwo (http://10.151.5.106:19000/index.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:30339:7)
at doResolve (http://10.151.5.106:19000/index.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:30503:15)
at new Promise (http://10.151.5.106:19000/index.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:30362:5)
`const firebaseConfig = {
apiKey: "xxxxxxxx",
authDomain: "bundle-find-staging.firebaseapp.com",
projectId: "bundle-find-staging",
storageBucket: "bundle-find-staging.appspot.com",
messagingSenderId: "524334210214",
appId: "xxxxxxxx",
};
const app = initializeApp(firebaseConfig);
const auth = getAuth(app);`
I've also tried with the persistence fix in #1847
`import { getReactNativePersistence } from "firebase/auth/react-native";
const firebaseConfig = {
...
};
let app: FirebaseApp;
let auth: Auth;
if (getApps().length < 1) {
app = initializeApp(firebaseConfig);
auth = initializeAuth(app, {
persistence: getReactNativePersistence(AsyncStorage),
});
} else {
auth = getAuth();
app = getApp();
}`
The text was updated successfully, but these errors were encountered: