Skip to content
This repository was archived by the owner on Dec 8, 2020. It is now read-only.
This repository was archived by the owner on Dec 8, 2020. It is now read-only.

Fix URI creation from path #385

Description

@aeschli

In 1.26 we discovered that several extensions probably call the 'vscode.openFolder' command with invalid file URIs:

kalitaalexey.vscode-rust/out/src/components/cargo/cargo_manager.js
  `373,53:                     vscode.commands.executeCommand('vscode.openFolder', uri, true);`
kalitaalexey.vscode-rust/out/src/components/cargo/CargoManager.js
  `192,55:                     vscode_1.commands.executeCommand('vscode.openFolder', uri, true);`

When creating a URI from a file path, always use vscode.URI.file(path), e.g vscode.URI.file('c:\\test')
Use vscode.URI.parse(uriString) when the input string is in the form scheme://authority/path

See microsoft/vscode#57267 for more information or for questions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions