Open Serginho opened 4 years ago
We have the same problem on Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.29 Safari/537.36
.signIn({prompt: 'consent'}).then(function() {...}) doesn't call the code in .then() block after google login window is closed.
Further research showed that the problem appears on other builds of Chrome/79: "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.29 Safari/537.36" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.16 Safari/537.36" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) HeadlessChrome/79.0.3945.0 Safari/537.36"
Chrome/78 and earlier works correctly.
Run this code in console before pressing your login button:
window.addEventListener('message',(...args)=>console.log(args))
You may see some relevant errors in the console afterwards.
@steveetm Yes 3 event from dpi iframe.
"{"method":"fireIdpEvent","params":{"type":"sessionSelectorChanged","newValue":{"hint":...
"{"method":"fireIdpEvent","params":{"type":"authResult","clientId":...
"{"id":"xxx-xxxxxxxxxxx","result":{"error":"user_logged_out"},"rpcToken":...
In firefox works properly and send 4 messages.
Our further research showed that the problem has been fixed starting the build 79.0.3945.36
@SergeMakDev In Chrome Canary OSX 80.0.3966.0's still not working and neither Chrome beta android 79.0.3945.36
@grant Maybe could you please give us some additional information about this? We don't know if this issue will be fixed quickly or we have to make a fix using OAuth 2 REST api.
We're seeing this issue also, even with 79.0.3945.36. As it seems like a Chrome bug, has anyone reported it on the chromium bug tracker yet? I did some searching but couldn't find it.
@jordan-thoms No we didn't report it cause we are not sure if it's actually a chrome bug, we know it doesn't work in chrome, but... what's the problem? the library is obfuscated so it's impossible to debug.
I've reported this at https://bugs.chromium.org/p/chromium/issues/detail?id=1024992 now, please add any additional information there and star the bug. It seems most likely that it's a Chrome issue as it is platform specific and worked in earlier versions.
It is a duplicate of #561 . Just try to disable same-site cookies in chrome, and it will work. Check that thread and the report date.
In a chrome thread I was told make sure that all third-party apis ready for this. And the third(?:D)-party api in this case is google-apis. Honestly, I don't know what is going on.
@steveetm Yeah you're right, disabling the flag fixes it. So the inconsistent behaviour here will just be depending on if you have the flag on/off as they are doing a partial rollout. I'm assuming Google will make sure this doesn't hit stable without at least updating their own services to be compatible!
Any update on this? The problem still exists
Hello,
I am experiencing the same issue with not having the resolve callback fire after calling .signIn(options)
--
I tested this with different browsers on Mac:
I've looked at the related issues around this promise not resolving properly, is there any update to chrome desktop experience?
I tried to circumvent the whole thing by using the signIn2.render
button generator, but the success callback on load will fire too early, sometimes.
thanks in advance, looking forward to hearing from you. Best, Isa
I have this exact same issue, still in mid-2021. On chrome for ios (only), the signin promise does not resolve most of the time (but sometimes it does). It works on all other platforms/browsers.
@steveetm Yes 3 event from dpi iframe.
"{"method":"fireIdpEvent","params":{"type":"sessionSelectorChanged","newValue":{"hint":...
"{"method":"fireIdpEvent","params":{"type":"authResult","clientId":...
"{"id":"xxx-xxxxxxxxxxx","result":{"error":"user_logged_out"},"rpcToken":...
In firefox works properly and send 4 messages.
More specifically, I have this exact same probleme, with sessionSelectorChanged
and "error":"user_logged_out"
More specifically, I have this exact same probleme, with
sessionSelectorChanged
and "error":"user_logged_out"
I've was investigating this same problem yesterday, seeing the same user_logged_out
error, and I was able to trace that to some weird issues with magic strings missing in cookies:
https://github.com/anthonyjgrove/react-google-login/issues/451#issuecomment-858148763
In my case, it was on an android device.
I tested this with different browsers, operative systems and google accounts. We conclude:
When code fails is because
window.gapi.auth2.getAuthInstance().signIn
callback is not called after google login window/tab is closed.It seems the client library isn't able to communicate with the window/tab.