Skip to content

explorer.upload fails when a file is selected #206274

@benvillalobos

Description

@benvillalobos

Our tracking issue: https://github.com/microsoft/vscode-edu-extension/issues/1664#issuecomment-1962165842. Demo gif here: https://github.com/microsoft/vscode-edu-extension/issues/1664#issuecomment-1962159858

When executing explorer.upload while a file is selected, vscode fails with the following message:

When a file is selected
uploading foo.txt and foo.txt is selected

Unable to write file 'vscode-edu-user:/VSCode Edu Project/foo.txt/foo.txt' (Error: Unable to create folder 'vscode-edu-user:/VSCode Edu Project/foo.txt' that already exists but is not a directory)

To work around this, I've considered detecting if a file is selected and showing a warning message to the user, but we can't get the currently selected file in the explorer today.

Version: 1.87.0-insider
Commit: e73419b
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36 Edg/121.0.0.0
Embedder: vscode.dev

Metadata

Metadata

Assignees

Labels

file-explorerExplorer widget issuesunder-discussionIssue is under discussion for relevance, priority, approach

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions