Skip to content

Revert "use vscode-vfs scheme for cloud session repo URIs (#298689)" - #300227

Closed
Osvaldo Ortega (osortega) wants to merge 1 commit into
mainfrom
copilot-worktree-2026-03-02T18-50-12
Closed

Revert "use vscode-vfs scheme for cloud session repo URIs (#298689)"#300227
Osvaldo Ortega (osortega) wants to merge 1 commit into
mainfrom
copilot-worktree-2026-03-02T18-50-12

Conversation

@osortega

Copy link
Copy Markdown
Contributor

This reverts the changes from PR #298689.

Changes

Restores the use of GITHUB_REMOTE_FILE_SCHEME for cloud session repository URIs by:

  1. repoPicker.ts - Re-adds the GITHUB_REMOTE_FILE_SCHEME import and uses it in _setRepo() instead of hardcoded vscode-vfs scheme
  2. sessionsManagementService.ts - Re-adds the GITHUB_REMOTE_FILE_SCHEME import and uses it in getRepositoryFromMetadata() for cloud sessions

This reverts commit from PR #298689.

This reverts the changes from PR #298689, restoring the use of
GITHUB_REMOTE_FILE_SCHEME for cloud session repository URIs.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Reverts PR #298689 by restoring use of the GITHUB_REMOTE_FILE_SCHEME scheme when constructing cloud session repository URIs in the Agent Sessions window (vs/sessions).

Changes:

  • Reintroduce GITHUB_REMOTE_FILE_SCHEME import and use it when setting the repo URI in the cloud repo picker.
  • Reintroduce GITHUB_REMOTE_FILE_SCHEME import and use it when deriving the repository URI from cloud session metadata.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
src/vs/sessions/contrib/sessions/browser/sessionsManagementService.ts Reverts cloud-session repository URI construction back to GITHUB_REMOTE_FILE_SCHEME.
src/vs/sessions/contrib/chat/browser/repoPicker.ts Reverts repo picker’s cloud repo URI scheme back to GITHUB_REMOTE_FILE_SCHEME.

Comment on lines 205 to 207
if (session.providerType === AgentSessionProviders.Cloud) {
return [URI.parse(`vscode-vfs://github/${metadata.owner}/${metadata.name}`), undefined];
return [URI.parse(`${GITHUB_REMOTE_FILE_SCHEME}://github/${metadata.owner}/${metadata.name}`), undefined];
}

Copilot AI Mar 9, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For cloud sessions this constructs a repo URI from metadata.owner/metadata.name without validating they are present and strings. If either is missing, this will produce a URI containing undefined segments (and then get used as the active session repository label/key). Consider mirroring the safer pattern used elsewhere (e.g. casting to string | undefined and returning undefined when owner/name are not set) before building the URI.

Copilot uses AI. Check for mistakes.
@vs-code-engineering vs-code-engineering Bot locked and limited conversation to collaborators Apr 23, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants