-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Hub does not currently emit an event when a refresh token expires or access token expires #12812
Comments
Seems there is no counter or task running that checks the expiry time of token and then dispatch the event. |
hello @mrSingh007 . Thank you for bringing this up. We currently have a fix for this issue which needs to be released. |
Hello @mrSingh007 . The latest release included the fix, you should be able to get the hub event when the |
I have tested now in 5.3.15 and in version 6.0.12 of 'aws-amplify' and the issue is still there. No any event was dispatched, when token is expired. |
@mrSingh007 you want an specific event when access or id token are expired? What is the use case? Thanks! |
@mrSingh007 you should be able to see |
@mrSingh007, did you get a chance to see @elorzafe's comment above? We'd like to know if there's additional context/use cases around this feature that we could work on. Would having just the expiration of the access token emit an event be enough here? |
Hey, @mrSingh007 👋. It looks like you may have had a similar question/issue resolved in #12832. Since we haven't heard back from you on this issue, we'll close this out for now. Feel free to reply back if there's still a question or blocker here, thanks! |
Before opening, please confirm:
JavaScript Framework
Angular
Amplify APIs
Authentication
Amplify Version
v6
Amplify Categories
auth
Backend
None
Environment information
Describe the bug
When access or refresh token is expired, no any event is sent to channel 'auth'. Page need to refresh manually to get new access token.
Expected behavior
When ever refresh token or access token expired, Hub should receive an event for 'auth' channel.
Reproduction steps
install the latest versions as mentioned above.
Listen to events as following:
Used config:
Code Snippet
// Put your code below this line.
Log output
aws-exports.js
No response
Manual configuration
No response
Additional configuration
No response
Mobile Device
No response
Mobile Operating System
No response
Mobile Browser
No response
Mobile Browser Version
No response
Additional information and screenshots
No response
The text was updated successfully, but these errors were encountered: