Closed fuyu0425 closed 1 month ago
我的 basedpyright 不提供 semantic 的 provider , 我暂时无法测试。
我盲修了一个补丁 https://github.com/manateelazycat/lsp-bridge/commit/5fa2ef56aae9d5bbcc388248aed0c35246216e7c 你更新看看, 能否解决这个问题?
https://github.com/manateelazycat/lsp-bridge/blob/5fa2ef56aae9d5bbcc388248aed0c35246216e7c/core/lspserver.py#L752 原本 single server 会自动 set semantic_tokens_provider returned by basedpyright
新的 error
--- [22:03:45.251833] Recv textDocument/semanticTokens/full response (38673) from 'basedpyright' for project mu4e_utils.py
Error when processing response 38673
Traceback (most recent call last):
File "/Users/fuyu0425/.spacemacs.d/site-lisp/lsp-bridge/core/handler/__init__.py", line 38, in handle_response
self.process_response(response)
File "/Users/fuyu0425/.spacemacs.d/site-lisp/lsp-bridge/core/handler/semantic_tokens.py", line 46, in process_response
self.update_tokens(self.tokens)
File "/Users/fuyu0425/.spacemacs.d/site-lisp/lsp-bridge/core/handler/semantic_tokens.py", line 62, in update_tokens
faces_index = self.get_faces_index(tokens[index + 3], tokens[index + 4])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/fuyu0425/.spacemacs.d/site-lisp/lsp-bridge/core/handler/semantic_tokens.py", line 75, in get_faces_index
type_name = lsp_server.semantic_tokens_provider["legend"]["tokenTypes"][type_index]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'list' object has no attribute 'semantic_tokens_provider'
再更新一下吧
可以了 感谢 🙏🏻
Errors when using basedpyright_ruff, not when using only basedpyright
Looks like it hardcodes
self.file_action.single_server