Open doc-rj-celltrak opened 3 years ago
Hi, is there any update on this issue?
To signout of the hostedUI, device needs to be online. Calling local signout will clear tokens, but hostedUI signout requires calling Cognito logout endpoint. Unlike iOS, Android custom tabs does not support private sessions due to which signout has to rely on successful hostedUI request.
Describe the bug
When offline and signed in via hosted UI (showSignIn), signing out fails.
When signing out with invalidateTokens=true, it leaves the user with a "no internet" error on the web page.
When signing out with invalidateTokens=false, the user is automatically signed in (without credentials) the next time showSignIn is called. The same thing happens when plain signOut with no parameters is called.
Neither of these paths allows for signing out while offline. This issue was recently fixed for iOS with new APIs -- https://github.com/aws-amplify/aws-sdk-ios/issues/3141 https://github.com/aws-amplify/amplify-ios/pull/1037
To Reproduce
Which AWS service(s) are affected?
Cognito
Expected behavior
When signed in with hosted UI, the user should be able to sign out when the device is offline (no network connectivity). Currently, the user is unable to sign out properly.
Screenshots
Environment Information (please complete the following information):
Additional context
This issue was recently fixed in the iOS SDK with new APIs, and offline sign out is now possible -- https://github.com/aws-amplify/aws-sdk-ios/issues/3141 https://github.com/aws-amplify/amplify-ios/pull/1037