这件事只是突然发生的,我目前正在使用 Linux Mint OS,我从文件管理器打开了我的远程项目,并打开了包含代码的目录,但 VS 代码突然无法打开目录中的任何文件。
[2022-02-07 14:31:46.792] [renderer1] [error] Error: Unable to read file '/run/user/1000/gvfs/ftp:host=HERE_IS_IP_OF_MY_REMOTE/watchdogbot/index.php' (Unknown (FileSystemError): An unknown error occurred. Please consult the log for more details.)
我在日志中收到的完整错误如下:
at Object.error (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:578:42065)
at Object.onError (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:67:28451)
at vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:67:27546
at vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:67:25727
at Array.forEach (<anonymous>)
at I.emitError (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:67:25716)
at I.error (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:67:25377)
at vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:574:12003
at o.fire (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:67:1712)
at K (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:83:3429)
at D.onResponse (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:83:4402)
at D.onBuffer (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:83:4242)
at vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:83:1817
at o.fire (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:67:1712)
at EventEmitter.G (vscode-file://vscode-app/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js:65:50696)
at EventEmitter.emit (events.js:315:20)
at Object.onMessage (electron/js2c/renderer_init.js:105:1177)
现在我已经尝试重新安装 VS 代码,但没有任何变化,它仍然无法打开任何文件。我尝试在谷歌上搜索这个问题,结果发现可能是路径出了问题,但重新安装通常可以解决问题,但事实并非如此……