Skip to content

Fix URI creation from path #1

@aeschli

Description

@aeschli

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

basys.vscode-basys/src/extension.js
49,45: await vscode.commands.executeCommand('vscode.openFolder', vscode.Uri.parse(dirObj[0].path));

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