-
Notifications
You must be signed in to change notification settings - Fork 389
P0 issue: accessing .auth() throwing error that util.promisify() was not receiving a function! breaks several of our applications #1295
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 downgraded my firebase-admin package to 8.4.0 and it works, so hopefully that can help narrow it down! Something deployed between 8.4.0 and now is definitely the source of the issue! |
Hi @pfinazzo, You mentioned that by commenting out |
The error is actually thrown by one of the dependencies (
You should be able to reproduce the error by just putting the above 3 lines into a file, and trying to execute it. The root cause here is that
@pfinazzo you should be able to resolve the issue by upgrading your Node.js version to v10.13.0 or higher in your deployment (your local environment probably already has a newer version). I'd actually recommend upgrading all the way to Node.js v12 since v10 has EoL'ed, and no longer recommended for production deployments. @lahirumaramba we should probably update the Node.js requirement in our |
P.S. Actually Jose's Node.js requirement is pretty well documented: https://github.com/panva/jose/tree/v2.0.5#usage (so that's WAI). |
Hi thank you so much for your replies @hiranya911 and @lahirumaramba, I will try upgrading my node version on my heroku server to see if it resolves it! I had tried upgrading my firebase-admin package, to the latest version (9.8.0) package, but my guess is @hiranya911 is right and I need to upgrade my node! thanks again for your help! |
@lahirumaramba I was using the .auth() method from firebase-admin npm package https://firebase.google.com/docs/reference/admin/node/admin.auth |
Updated the Node.js requirement in our |
[REQUIRED] Step 2: Describe your environment
[REQUIRED] Step 3: Describe the problem:
My Heroku Server randomly started crashing recently and wont boot back up (even though it works perfectly fine locally). If I comment out
const firebaseAdmin = firebaseApp.auth()
, then it deploys with no crash, but as soon as I comment it back in, it crashes. This is breaking our applications and so this has become a P0 issue for us. Any help would be greatly appreciated. I will post screenshots of the error and the line of code I commented out that fixed the error. Thank you!Steps to reproduce:
Deploy a heroku server and import the firebase-admin sdk and call the
.auth()
method with the same node and npm env. This issue has arisen within the past week, I'm not sure exactly when it started.Relevant Code:
Error:

Fixed by commenting out:

I've gone through and tested it several times over, and consistently this ^ is the line of code causing it to crash.
Again this is NOT happening locally but for some reason only on a deployed heroku dyno instance.
Any help on this would be SUPER appreciated because it is currently breaking several of our apps
our
firebaseApp
firebase configuration has been working perfectly up until around last week and the error does not get thrown until.auth()
is called so Im inclined to believe we have everything set up properly, unless something has changed recently about how it should all be setup configuration wiseThe text was updated successfully, but these errors were encountered: