When getAccessTokenSilently rejects with login_required, invalid_grant, missing_refresh_token, consent_required, or interaction_required, call auth0.logout({ openUrl: false })
Keeps the UI honest: previously the app showed the user as logged in while every authenticated query silently failed, until they manually logged out and back in
Why
Paired with the backend change to make Origins tolerate missing subjects, this prevents the misleading "logged in but nothing works" state seen on mobile cold starts.
Test plan
npm run lint
Verify on phone: stale auth flips UI to logged-out instead of looking logged-in with empty events
## Summary
- When `getAccessTokenSilently` rejects with `login_required`, `invalid_grant`, `missing_refresh_token`, `consent_required`, or `interaction_required`, call `auth0.logout({ openUrl: false })`
- Keeps the UI honest: previously the app showed the user as logged in while every authenticated query silently failed, until they manually logged out and back in
## Why
Paired with the backend change to make `Origins` tolerate missing subjects, this prevents the misleading "logged in but nothing works" state seen on mobile cold starts.
## Test plan
- [x] `npm run lint`
- [ ] Verify on phone: stale auth flips UI to logged-out instead of looking logged-in with empty events
When getAccessTokenSilently fails with login_required, invalid_grant,
missing_refresh_token, consent_required or interaction_required, log
the user out (without redirect) so the UI reflects reality instead of
appearing logged in while every authenticated query silently fails.
argoyle
scheduled this pull request to auto merge when all checks succeed 2026-05-05 17:31:33 +00:00
argoyle
merged commit 189e35acf8 into main2026-05-05 17:37:01 +00:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Summary
getAccessTokenSilentlyrejects withlogin_required,invalid_grant,missing_refresh_token,consent_required, orinteraction_required, callauth0.logout({ openUrl: false })Why
Paired with the backend change to make
Originstolerate missing subjects, this prevents the misleading "logged in but nothing works" state seen on mobile cold starts.Test plan
npm run lint