--- [23:17:50.807261] Send initialized notification to 'rust-analyzer' for project cs110
[ERROR rust_analyzer::config] failed to find any projects in [AbsPathBuf("/home/unioun/course/code/cs110")]
--- [23:17:50.807501] Send workspace/didChangeConfiguration notification to 'rust-analyzer' for project cs110
--- [23:17:50.807637] Send textDocument/didOpen notification to 'rust-analyzer' for project cs110
[ERROR rust_analyzer::main_loop] FetchWorkspaceError:
rust-analyzer failed to discover workspace
--- [23:17:50.809512] Recv window/showMessage notification from 'rust-analyzer' for project cs110
--- [23:17:50.809835] Recv workspace/configuration request (0) from 'rust-analyzer' for project cs110
[ERROR rust_analyzer::main_loop] FetchWorkspaceError:
rust-analyzer failed to discover workspace
反馈一下,可能有人碰到同样的问题。 lsp-bridge 大概是根据git目录来向发送请求的,然而在我的这个作业中,包在git目录的子目录下,Cargo new创建的包里面没有 git文件,请求失败。使用 git init 问题解决。
--- [23:17:50.807261] Send initialized notification to 'rust-analyzer' for project cs110 [ERROR rust_analyzer::config] failed to find any projects in [AbsPathBuf("/home/unioun/course/code/cs110")]
--- [23:17:50.807501] Send workspace/didChangeConfiguration notification to 'rust-analyzer' for project cs110
--- [23:17:50.807637] Send textDocument/didOpen notification to 'rust-analyzer' for project cs110 [ERROR rust_analyzer::main_loop] FetchWorkspaceError: rust-analyzer failed to discover workspace
--- [23:17:50.809512] Recv window/showMessage notification from 'rust-analyzer' for project cs110
--- [23:17:50.809835] Recv workspace/configuration request (0) from 'rust-analyzer' for project cs110 [ERROR rust_analyzer::main_loop] FetchWorkspaceError: rust-analyzer failed to discover workspace