FileStat permissions is always undefined for readonly files #673
-
Has const stat: vscode.FileStat = await vscode.workspace.fs.stat(uri);
if (stat.permissions === vscode.FilePermission.Readonly) {}
|
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
I'm not aware of any, but I guess the recent work by @jackpunt and @bpasero may have affected this. |
Beta Was this translation helpful? Give feedback.
-
Please first figure out if this used to work and now does not work anymore. As far as I can tell, we never reported To help us narrow down what change caused the issue, please run the following command to find the build. It will start previous releases of VS Code insiders to see where the regression was introduced:
|
Beta Was this translation helpful? Give feedback.
-
I assume you are saying that for a file set to read-only in the OS, that When I set a file to const activeUri = vscode.window.activeTextEditor.document.uri;
const stats = await vscode.workspace.fs.stat(activeUri); The |
Beta Was this translation helpful? Give feedback.
Please first figure out if this used to work and now does not work anymore. As far as I can tell, we never reported
FilePermission.Readonly
for files that are readonly on disk.To help us narrow down what change caused the issue, please run the following command to find the build. It will start previous releases of VS Code insiders to see where the regression was introduced:
npx --yes vscode-bisect@latest