Skip to content

fix(auth): isolate requests across deployment sessions - #1174

Merged
EhabY merged 1 commit into
mainfrom
fix/workspace-session-isolation
Nov 13, 2026
Merged

EhabY merged 1 commit into
mainfrom
fix/workspace-session-isolation

Conversation

@EhabY

@EhabY EhabY commented Oct 30, 2026 •

Copy link
Copy Markdown
Collaborator

Rebinding the API client to another deployment or account cancels its pending requests, while token refreshes for the same account keep them, in both the local client and remote windows.

  • CoderApi.setCredentials and dispose abort pending requests; setSessionToken keeps them.
  • DeploymentManager treats a token change as a refresh only when the user ID and URL match, and clears the client before announcing sign-out.
  • Remote windows verify the user behind a new token before keeping requests, and reset OAuth on an account change.
  • The auth interceptor does not refresh, prompt or retry for a canceled request.
  • An OAuth refresh canceled midway never overwrites the credentials that replaced it.

Required by #1168.

Generated by Coder Agents on behalf of @EhabY.

🤖 Generated with Claude Code

@EhabY
EhabY force-pushed the fix/workspace-session-isolation branch 2 times, most recently from 1e6f9e7 to 549e84b Compare October 30, 2026 21:54
@EhabY
EhabY force-pushed the fix/workspace-session-isolation branch 2 times, most recently from c3e5d9e to a05dbb0 Compare November 9, 2026 10:21
@EhabY
EhabY marked this pull request as ready for review November 9, 2026 11:54
@EhabY
EhabY force-pushed the fix/workspace-session-isolation branch 2 times, most recently from 750c24d to ae9c9e4 Compare November 9, 2026 11:58
@EhabY
EhabY force-pushed the fix/workspace-session-isolation branch from ae9c9e4 to 750c24d Compare November 9, 2026 12:01
@EhabY
EhabY added this pull request to stack #1185 November 9, 2026 12:24
@EhabY
EhabY requested a review from aqandrew November 9, 2026 18:06
@linear-code

linear-code Bot commented Nov 10, 2026

Copy link
Copy Markdown

VSC-46

@EhabY
EhabY force-pushed the fix/workspace-session-isolation branch from 750c24d to be84be5 Compare November 12, 2026 15:07
Generated by Coder Agents on behalf of @EhabY.
@EhabY
EhabY force-pushed the fix/workspace-session-isolation branch from be84be5 to ced9b0e Compare November 12, 2026 23:13
@EhabY
EhabY merged commit c5957d4 into main Nov 13, 2026
11 of 12 checks passed
@EhabY
EhabY deleted the fix/workspace-session-isolation branch November 13, 2026 14:12
EhabY added a commit that referenced this pull request Nov 13, 2026
@EhabY EhabY mentioned this pull request Nov 13, 2026
EhabY added a commit that referenced this pull request Nov 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants