firebase / firebase/firebase-js-sdk

getAuth dies and shows nothing on capacitor

Open
#7,597 0 comments 3 reactions 0 assignees View on GitHub
api: auth feature request needs-attention
Dominant language
TypeScript
Stars
5.1k
Forks
1k
Avg merge
2d 21h
Merged PRs (30d)
37

Description

### Operating System

ios latest or something

### Browser Version

whatever ios uses. apple will never tell us for realz

### Firebase SDK Version

9.23.currently.awesome

### Firebase SDK Product:

Auth

### Describe your project's tooling

https://github.com/firebase/firebase-js-sdk/issues/5019

I spent better part of 3 days debugging this issue. So have others.

It would appear that `getAuth` just... dies in browser that firebase "doesn't support"

But, like, it's just javascript. functions don't just... die. They have errors. They log stack traces when they fail. Not this one.

Poof.

I kid you not I had this code:

console.log('calling getAuth')
this._auth = getAuth(this.firebaseApp)
console.log('done')

and my ios, capacitor, app just **stopped** with the message: 'calling getAuth'
zero additional information.

I understand not supporting every platform under the moon... but what on cloud 13 is this function doing that it's just like... nah, I'm not going to show any evidence whatsoever of my invocation. and also I'm going to do nothing. and also I'm going to stop the runtime in its tracks.

🤯 🤯 🤯

Please. Make it log something. Save people some time.

I mean look at all these people with the same issue:
https://github.com/firebase/firebase-js-sdk/issues?q=is%3Aissue+is%3Aopen+capacitor

Like half of those are this issue. (Okay, okay, I only opened 2 of them - but it's PROBABLY half!)

### Describe the problem

oh wait, there's another field? I described it already.

### Steps and code to reproduce issue

no. i refuse to reproduce this issue. if I reproduce it again we'll all slip into the singularity.

Contributor guide

Open the contributing guide

Research direction

Start at the Auth product's getAuth entry point and examine its behavior in an iOS Capacitor browser context. Reproduce the reported call if possible; done means an unsupported-platform failure produces an observable error or log instead of stopping after “calling getAuth”.

Written by the indexing model from the issue text.

Assessment

Tech stack
ios, javascript, typescript
Domain
authentication, mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.