-
Notifications
You must be signed in to change notification settings - Fork 960
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
beforeSignin functions doesn't trigger in emulator for demo projects? #6494
Comments
Hi @renaudcerrato, thanks for the detailed report. I’m currently unable to reproduce the behavior you mentioned. Using the code snippets you provided, I created this repo to try and replicate the issue. Let me know in case I’m missing anything. I added an initializeApp({
projectId: "demo-test",
apiKey: "useless",
authDomain: "demo-test.firebaseapp.com",
databaseURL: "https://demo-test.firebaseio.com",
}) And removed a section in the functions code related to the Admin SDK: import {beforeUserSignedIn} from "firebase-functions/v2/identity"
export const beforesignin = beforeUserSignedIn(async (event) => {
console.log(" ------------- beforeUserSignedIn --------------- ");
console.log(`beforesignin: ${JSON.stringify(event.data)}`)
}) By any chance, if you’re unable to reproduce the issue using the repo, could you provide a Minimal, Complete, and Verifiable Example (MCVE)? This is so that we can replicate the issue on our end. |
Thanks for the repo, it seems the |
Hey @aalej : just been able to reproduce the issue in your repo by adding a pubsub function to the project. Please look at aalej/issues-6494#1 |
Thanks @renaudcerrato for additional information. I was able to reproduce the issue you mentioned after adding the code you provided. I’ll notify our engineering team about this so that they can take a look, and I’ll be marking this as reproducible. |
I'm trying to get the
beforeSignin
trigger function to work using the emulator on demo projects (--project demo-xxxx
/ 12.7.0 / macOS) but that's not triggering while perfectly working in production. I'm able to login and write to thedatabase
in the emulator, but nobeforeSignin
trigger. I've spent the whole day trying, but nothing in the logs.I double checked that both
auth
andfunctions
are started and running in the emulator, and correctly set theprojectId
todemo-test
in my client as suggested:I also tried to to set the
projectId
in the function, which should be useless, but with no luck:Is there anything else I'm not aware of to get it working on demo-projects emulation ?
The text was updated successfully, but these errors were encountered: