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

Add LanguageServerOption For Diagnostics #8622

Merged
merged 4 commits into from
Apr 24, 2023
Merged

Conversation

lonitra
Copy link
Member

@lonitra lonitra commented Apr 21, 2023

Add SupportsDelegatedDiagnostics language server option and request for diagnostics only if it is true.
Related: https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1806769

@lonitra lonitra requested a review from a team as a code owner April 21, 2023 19:42
@lonitra lonitra enabled auto-merge (squash) April 21, 2023 23:15
Copy link
Contributor

@davidwengier davidwengier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Exception based programming is never fun.

The real solution here is to add a new LanguageServerFeatureOption for SupportsDelegatedDiagnostics, just like we have to SupportsDelegatedCodeActions, and then just not issue the request at all.

@lonitra lonitra disabled auto-merge April 22, 2023 00:00
@lonitra lonitra changed the title Add Try/Catch to Diagnostic Request Add LanguageServerOption For Diagnostics Apr 22, 2023
Copy link
Contributor

@davidwengier davidwengier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome!

@lonitra lonitra enabled auto-merge (squash) April 24, 2023 17:02
@lonitra lonitra merged commit 85ecea5 into dotnet:main Apr 24, 2023
@lonitra lonitra deleted the trycatch branch April 24, 2023 17:45
dibarbet pushed a commit to dibarbet/vscode-csharp that referenced this pull request Jun 8, 2023
…rverClient

Follow up for: dotnet/razor#8622
Set SupportsDelegatedDiagnostics On RazorLanguageServerClient so that C# diagnostic requests only come in on new C# extension.
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

Successfully merging this pull request may close these issues.

3 participants