Closed andreas-prouza closed 1 month ago
VS Code Desktop:
If I click on the Create File
I see a permission error:
The path is valid. If I copy the path to the terminal (using echo) I am able to click on the path link to open the file.
I created the path outside the coder-workspace on my local machine. Now it worked and I could create the file without permission error. That means, the link tries to access the file path not in the coder workspace but on my machines file system!
The link to open a file looks the following: 📝 Open project config file
In the tree-view it's the same.
There I add for the tree entries the command attribute:
this.command = {
command: 'vscode.open',
title: 'Open source member',
arguments: [{
scheme: 'file',
path: '/home/Andreas/projekte/ibm-i-build-obi/src/prouzalib/qddssrc/file1.pf.file',
authority: ''
}]
}
Usually this is also working fine.
Yeah, I think when it comes to VS Code web (code-server, Codespaces), you have to use the vscode-remote
scheme so it knows that the file is on the remote and not a local file. I am not sure if there is a clean way to use vscode-remote
in web and file
in local though, that would be a better question for the VS Code folks.
Many thanks for your answer. I guess I need to find a way to distinguish here. But you helped me to get one step forward 🙂
Is there an existing issue for this?
OS/Web Information
code-server --version
: Coder v2.15.0+190cd1cSteps to Reproduce
I published an extension which runs in vscode, theia and code oss. Only when using it with coder, it has problems to open file link in webview or tree-view.
Steps to Reproduce:
.obi
)Open project config file
. Click on itExpected
The file gets opened
Actual
Get an error
Logs
In local VS Code Desktop:
In code-server:
Screenshot/Video
No response
Does this bug reproduce in native VS Code?
No, this works as expected in native VS Code
Does this bug reproduce in GitHub Codespaces?
I did not test GitHub Codespaces
Are you accessing code-server over a secure context?
Notes
The webview link looks like the following: Open project config file