Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When the notes file already exists, the extension registers an error #5

Open
dlipovetsky opened this issue Dec 13, 2022 · 0 comments
Open
Assignees

Comments

@dlipovetsky
Copy link

dlipovetsky commented Dec 13, 2022

When I "toggle" the notes open, and the notes file already exists, I see this in the "Window" output:

2022-12-12 17:26:44.688 [error] Error: Unable to create file '/home/user/project/.vscode/notes.md' that already exists when overwrite flag is not set
   at h.r (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:616:13783)
   at async h.canCreateFile (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:616:13680)
   at async Promise.all (index 0)
   at async Object.K [as settled] (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:89:21254)
   at async i.doCreateFileOrFolder (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:2485:62284)
   at async s.perform (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:2491:18459)
   at async a.apply (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:2491:21499)
   at async v.n (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:2491:23574)
   at async v.perform (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:2491:23250)
   at async m.apply (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:2491:25167)
2022-12-12 17:26:44.688 [warning] IGNORING workspace edit: Error: Unable to create file '/home/user/project/.vscode/notes.md' that already exists when overwrite flag is not set

I'm not sure if there's a way to avoid this, given the API.

Thanks for the creating this extension! ❤️

@sunliangqin sunliangqin self-assigned this Jan 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants