-
-
Notifications
You must be signed in to change notification settings - Fork 483
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
feat(language_server)!: add capability diagnosticProvider
#7444
feat(language_server)!: add capability diagnosticProvider
#7444
Conversation
Your org has enabled the Graphite merge queue for merging into mainAdd the label “0-merge” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. Or use the label “hotfix” to add to the merge queue as a hot fix. You must have a Graphite account and log in to Graphite in order to use the merge queue. Sign up using this link. |
@@ -31,43 +33,26 @@ struct Backend { | |||
client: Client, | |||
root_uri: OnceCell<Option<Url>>, | |||
server_linter: RwLock<ServerLinter>, | |||
document_content_cache: DashMap<String, String>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I do know now if this could lead to performance problems. We need to keep all content of any open file in the memory.
I've invited you and @nrayburn-tech as collaborators to help with review. |
I don't think IntelliJ currently supports pulling diagnostics, so this would be a pretty big blocker for the IntelliJ plugin. Either the IntelliJ plugin would have to implement this functionality or wait until it is added to IntelliJ. I don't think it's worth merging until IntelliJ has support for this. I didn't review the actual changes much given the lack of IntelliJ support. |
I dont think this will come in the near future 😢
The community is not happy about this: https://blog.jetbrains.com/platform/2023/07/lsp-for-plugin-developers/ Closing for now, maybe we change our minds in the future |
I don’t have specifics, but my guess is that if we didn’t use the language server then the effort involved to maintain the JetBrains plugin would significantly increase. There might be community alternatives available that do something similar, but I don’t know off hand. @Boshen is it worth discussing using something other than the official language server support in JetBrains IDEs? FYI @IWANABETHATGUY since you started the plugin. |
The current implementation checks on onChange / onSave. There they will respect the
run
option.This is not optimal because the client is sending events, which will be ignored by the server.
This implementation uses the feature, that the client requests diagnostics from the server.
https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#textDocument_pullDiagnostics