Closed woutersteven closed 10 months ago
I've tested it with the latest SDK v10.2.0, but the issue remains. Just keeping it update here for reference.
I've tested it with the latest SDK v10.3.0 and v10.3.1a nd v10.4.0, and the issue remains (just listing for reference and if others are encountering the issue). When I've more updates I'll post them here.
Can you try comparing the URLs when using v9 and v10?
Is the v=
the only difference in both?
You can try inspecting the network traces of the success and failure case too..
Good morning, thank you for your reply. I tried it out with all versions after 9.23. These are the results. It seems the difference is a section in the querystring: &providerId=google.com&scopes=profile
And that it stays on 9.23 in the querystring throughout.
Thanks! I notcied a couple of things:
1) I see the authType shows "signInViaPopup", but i think the issue was previously on signInViaRedirect, correct? The redirect URL is computed here - https://github.com/firebase/firebase-js-sdk/blob/e30d7a6522fd3be0c30a82ee054b271a68c03fde/packages/auth/src/platform_browser/popup_redirect.ts#L95, this is where we set the provider ID - https://github.com/firebase/firebase-js-sdk/blob/e30d7a6522fd3be0c30a82ee054b271a68c03fde/packages/auth/src/core/util/handler.ts#L86 and scopes is set few lines below. Can you confirm that you are passing in the correct "provider" parameter to signInWithRedirect or signInWithPopup? Any chance it is mistakenly triggering it for an Email/Password or similar provider?
Hey @woutersteven2020. 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!
The issue happens with both mode=redirect and mode=popup. I just did some more debugging.
Going over (a lot) of GitHub issues, I'm suspecting an incompatibility between AngularFire 7.6.1 and Firebase 10+. At least for some other errors that are triggered, for example by Firestore:
There were a few other issues that I cannot find now that were mentioning incompatibility between exports of functions between firebase and AngularFire. and a few seemingly unrelated errors/warnings that others reported.
I've downgraded to v9.23 again and will await the update of AngularFire and report back here.
Update for today.
Initial tests with AngularFire v16 and Firebase 10.5.1 look good. I will test more tomorrow and this weekend and report back here and potentially close this issue.
Currently using it with AngularFire v17.0.0 (pre-release) and Firebase v10.7.0, also working as expected. Closing issue...
Operating System
PWA
Browser Version
Chrome 115
Firebase SDK Version
10.0.0
Firebase SDK Product:
Auth
Describe your project's tooling
Ionic 7.3.1 / Angular 16.2.2
Describe the problem
Using firebase v10.0.0, v10.1.0, v10.2.0 or v10.3.0. the authentication flows break in a PWA setup and using signInWithGoogle. The error message in the browser is: "requested action is invalid". The PWA is hosted at Firebase with a custom domain, and both the custom domain and "localhost" are added to the list of authorised domains.
Downgrading to firebase v9.23 resolves the issue which is currently a work-around, and suggests that the configuration itself is correct.
Steps and code to reproduce issue
When using firebase v10.* I did notice a redirect containing a version number in the querystring to:
https:///__/auth/handler? apiKey=& appName=%5BDEFAULT%5D& authType=signInViaRedirect& redirectUrl=http%3A%2F%2Flocalhost%3A8101%2Fpages%2Flogin& v=9.23.0
Which i found odd considering I'm not using v9.23. However I've no idea what the issue is. Has anybody else encountered the issue?