{"action":"created","issue":{"url":"https://api.github.com/repos/lynndylanhurley/devise_token_auth/issues/1147","repository_url":"https://api.github.com/repos/lynndylanhurley/devise_token_auth","labels_url":"https://api.github.com/repos/lynndylanhurley/devise_token_auth/issues/1147/labels{/name}","comments_url":"https://api.github.com/repos/lynndylanhurley/devise_token_auth/issues/1147/comments","events_url":"https://api.github.com/repos/lynndylanhurley/devise_token_auth/issues/1147/events","html_url":"https://github.com/lynndylanhurley/devise_token_auth/issues/1147","id":315983019,"number":1147,"title":"A few refreshes after login gives me a blank access token and expiry, logging me out ","user":{"login":"djvs","id":2954343,"avatar_url":"https://avatars2.githubusercontent.com/u/2954343?v=4","gravatar_id":"","url":"https://api.github.com/users/djvs","html_url":"https://github.com/djvs","followers_url":"https://api.github.com/users/djvs/followers","following_url":"https://api.github.com/users/djvs/following{/other_user}","gists_url":"https://api.github.com/users/djvs/gists{/gist_id}","starred_url":"https://api.github.com/users/djvs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djvs/subscriptions","organizations_url":"https://api.github.com/users/djvs/orgs","repos_url":"https://api.github.com/users/djvs/repos","events_url":"https://api.github.com/users/djvs/events{/privacy}","received_events_url":"https://api.github.com/users/djvs/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2018-04-19T18:07:44Z","updated_at":"2018-05-08T20:43:58Z","closed_at":null,"author_association":"NONE","body":"When posting issues, please include the following information to speed up the troubleshooting process:\r\n\r\n* **Version**: which version of this gem (and [ng-token-auth](https://github.com/lynndylanhurley/ng-token-auth), [jToker](https://github.com/lynndylanhurley/j-toker) or [Angular2-Token](https://github.com/neroniaky/angular2-token) if applicable) are you using?\r\n\r\nUsing redux-token-auth which autorefreshes the token on validateCredentials.  Seems to mostly work fine until an invalid response.\r\n\r\n* **Request and response headers**: these can be found in the \"Network\" tab of your browser's web inspector.\r\n\r\nFirst one:\r\n```\r\nRequest URL:http://localhost:3000/api/auth/validate_token?access-token=JP7aoQJ0JCy50ksfdsF42Q&client=A72aCNAduLuSDjx0rGTVTA&uid=myemail@gmail.com\r\nRequest Method:GET\r\nStatus Code:200 OK\r\nRemote Address:127.0.0.1:3000\r\nReferrer Policy:no-referrer-when-downgrade\r\nResponse Headers\r\nview source\r\naccess-token:Hlc_RCopM1QX9a0NWegU3A\r\nCache-Control:max-age=0, private, must-revalidate\r\nclient:A72aCNAduLuSDjx0rGTVTA\r\nContent-Type:application/json; charset=utf-8\r\nETag:W/\"93ce4582abd43b223155086735015a04\"\r\nexpiry:1525370698\r\n```\r\n\r\nSecond one:\r\n```\r\nRequest URL:http://localhost:3000/api/auth/validate_token?access-token=Hlc_RCopM1QX9a0NWegU3A&client=A72aCNAduLuSDjx0rGTVTA&uid=myemail@gmail.com\r\nRequest Method:GET\r\nStatus Code:200 OK\r\nRemote Address:127.0.0.1:3000\r\nReferrer Policy:no-referrer-when-downgrade\r\nResponse Headers\r\nview source\r\naccess-token:\r\nCache-Control:max-age=0, private, must-revalidate\r\nclient:A72aCNAduLuSDjx0rGTVTA\r\nContent-Type:application/json; charset=utf-8\r\nETag:W/\"93ce4582abd43b223155086735015a04\"\r\nexpiry:\r\n```\r\n\r\n* **Rails Stacktrace**: this can be found in the `log/development.log` of your API.\r\n\r\nn/a\r\n\r\n* **Environmental Info**: How is your application different from the [reference implementation](https://github.com/lynndylanhurley/devise_token_auth_demo)? This may include (but is not limited to) the following details:\r\n  * **Routes**: are you using some crazy namespace, scope, or constraint?\r\n\r\nNo\r\n\r\n  * **Gems**: are you using MongoDB, Grape, RailsApi, ActiveAdmin, etc.?\r\n\r\nNothing unusual\r\n\r\n  * **Custom Overrides**: what have you done in terms of [custom controller overrides](https://github.com/lynndylanhurley/devise_token_auth/#custom-controller-overrides)?\r\n\r\nn/a\r\n\r\n  * **Custom Frontend**: are you using [ng-token-auth](https://github.com/lynndylanhurley/ng-token-auth), [jToker](https://github.com/lynndylanhurley/j-toker), [Angular2-Token](https://github.com/neroniaky/angular2-token), or something else?\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/lynndylanhurley/devise_token_auth/issues/comments/387536392","html_url":"https://github.com/lynndylanhurley/devise_token_auth/issues/1147#issuecomment-387536392","issue_url":"https://api.github.com/repos/lynndylanhurley/devise_token_auth/issues/1147","id":387536392,"user":{"login":"djvs","id":2954343,"avatar_url":"https://avatars2.githubusercontent.com/u/2954343?v=4","gravatar_id":"","url":"https://api.github.com/users/djvs","html_url":"https://github.com/djvs","followers_url":"https://api.github.com/users/djvs/followers","following_url":"https://api.github.com/users/djvs/following{/other_user}","gists_url":"https://api.github.com/users/djvs/gists{/gist_id}","starred_url":"https://api.github.com/users/djvs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djvs/subscriptions","organizations_url":"https://api.github.com/users/djvs/orgs","repos_url":"https://api.github.com/users/djvs/repos","events_url":"https://api.github.com/users/djvs/events{/privacy}","received_events_url":"https://api.github.com/users/djvs/received_events","type":"User","site_admin":false},"created_at":"2018-05-08T20:43:57Z","updated_at":"2018-05-08T20:43:57Z","author_association":"NONE","body":"@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"}}
{"actor":{"display_login":"djvs"}}