Skip to content

fix: IDE launch fails when opening a URI targeting a workspace owned …#324

Merged
fioan89 merged 1 commit into
mainfrom
fix-ide-failed-launch
Jun 24, 2026
Merged

fix: IDE launch fails when opening a URI targeting a workspace owned …#324
fioan89 merged 1 commit into
mainfrom
fix-ide-failed-launch

Conversation

@fioan89

@fioan89 fioan89 commented Jun 23, 2026

Copy link
Copy Markdown
Collaborator

…by a different user

When a Coder URI pointed to a workspace owned by a user other than the one currently authenticated, the IDE would fail to launch with a misleading error claiming no matching IDE version was available. The real problem was that the workspace poller only fetched the authenticated user's own workspaces, so the target workspace never made it into the plugin's environment registry. When the IDE launch tried to inspect that workspace, Toolbox reported it as non-existent, which cascaded into empty IDE lists and the confusing version mismatch error.

The fix intercepts URI handling — for both the same-deployment and new-deployment flows, and regardless of whether token, mTLS, or OAuth2 authentication is in use — and scopes the workspace filter to owner: name: before the protocol handler runs.
This ensures the poller fetches exactly the target workspace and registers it with Toolbox in time for the IDE launch to succeed.
When the URI targets the authenticated user's own workspace, the filter is reset to the default owner:me instead, which also cleans up any leftover non-owned filter from a previous URI.

  • resolves DEVEX-372
  • resolves DEVEX-374

…by a different user

When a Coder URI pointed to a workspace owned by a user other than the one currently authenticated, the IDE would fail to launch with a misleading error claiming no matching IDE version was available.
The real problem was that the workspace poller only fetched the authenticated user's own workspaces, so the target workspace never made it
into the plugin's environment registry. When the IDE launch tried to inspect that workspace, Toolbox reported it as non-existent, which cascaded into empty IDE lists and the confusing version mismatch error.

 The fix intercepts URI handling — for both the same-deployment and new-deployment flows, and regardless of whether token, mTLS, or OAuth2 authentication is in use — and scopes the workspace filter to owner:<x> name:<y> before the protocol handler runs.
 This ensures the poller fetches exactly the target workspace and registers it with Toolbox in time for the IDE launch to succeed.
 When the URI targets the authenticated user's own workspace, the filter is reset to the default owner:me instead, which also cleans up any leftover non-owned filter from a previous URI.

 - resolves DEVEX-372
 - resolves DEVEX-374
@linear-code

linear-code Bot commented Jun 23, 2026

Copy link
Copy Markdown

DEVEX-372

DEVEX-374

@fioan89 fioan89 merged commit 1b6388c into main Jun 24, 2026
6 checks passed
@fioan89 fioan89 deleted the fix-ide-failed-launch branch June 24, 2026 19:57
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