You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: sync authentication state across VS Code windows
Fixes#498 by implementing event-driven authentication synchronization.
When a user logs out from one VS Code window, all other windows now
immediately show a clear 'You've been logged out of Coder!' notification
instead of confusing errors like 'Invalid argument uriOrString'.
Uses ctx.secrets.onDidChange to detect session token changes and
syncAuth() to update all windows consistently.
- Add syncAuth() function to handle auth state changes
- Listen for sessionToken changes via ctx.secrets.onDidChange
- Update REST client, VS Code contexts, and workspace providers
- Show consistent logout notifications across windows
Tested: A/B validation confirms fix eliminates confusing user experience.
0 commit comments