-
Notifications
You must be signed in to change notification settings - Fork 1.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
A few refreshes after login gives me a blank access token and expiry, logging me out #1147
Comments
Additionally, manually verifying the token and client shows it's valid:
|
Also, if I change the initializer as so:
I no longer get the issue (at the cost of stopping token refreshes). |
Hi @djvs It is connected to #703 (comment) |
@djvs we're getting the same issue, but changing the initializer doesn't help us. @krzysiek1507 any ETA on a fix? this package is pretty much busted until this is fixed. |
@lightninglu10 I have no idea. I'm not a maintainer of the gem. |
@lightninglu10 I didn't have time to go in-depth so I just added a 1 second delay on all page loads before rendering the stuff inside the router, it seems to have done the trick |
Actually @djvs we set the initializer in the wrong place, that does actually help. No more refresh token but at least users aren't erroneously logged out! |
Seeing this issue as well! |
hey @ludazhao , in
I think you won't be able to get the refresh token so after 2 weeks or however long your auth session lasts for your user will be logged out, but at least they'll be logged in for 2 weeks. |
A blank If it is logging you out, that's something that you should fix in your frontend, which should consider that you can still consider your last token as the current one. |
Oh wow, that's the case? There's no docs about that anywhere. Are you using this gem as such @LeoGardel ? |
But should we set |
I just spend a whole day debugging this issue. It would be great to add this to the docs. |
devise_token_auth でアクセストークンが空で返ってくることがある lynndylanhurley/devise_token_auth#1147 解としてはコメントで言われているように、change_headers_on_each_requestをfalseにすることではなく、空であることを考慮すべきかと思う。 lynndylanhurley/devise_token_auth#1147 (comment) redux-token-auth 側で対応したPRがマージされないため、PR作者のブランチを取り込むこととした。 kylecorbelli/redux-token-auth#52 https://github.com/zopelee/redux-token-auth
Spent a decent amount of time debugging this as well. It should be added to the doc. |
So we have a PR up on redux-toen-auth, as this is their issue 🤷🏼♂️ , |
When posting issues, please include the following information to speed up the troubleshooting process:
Using redux-token-auth which autorefreshes the token on validateCredentials. Seems to mostly work fine until an invalid response.
First one:
Second one:
log/development.log
of your API.n/a
No
Nothing unusual
n/a
The text was updated successfully, but these errors were encountered: