-
Notifications
You must be signed in to change notification settings - Fork 121
Skip empty publishDiagnostics on didClose when client supports pull diagnostics #3721
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
Conversation
|
Important Review skippedBot user detected. To trigger a single review, invoke the You can disable this status message by setting the Note Other AI code review bot(s) detectedCodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review. Comment |
…iagnostics Co-authored-by: nixel2007 <[email protected]>
Test Results 312 files - 2 496 312 suites - 2 496 3m 4s ⏱️ - 50m 31s Results for commit e0fe3a4. ± Comparison against base commit e5b5781. This pull request removes 8 and adds 6 tests. Note that renamed tests count towards both.♻️ This comment has been updated with latest results. |
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.
Pull request overview
This PR implements LSP spec-compliant behavior by preventing servers from sending publishDiagnostics notifications when clients use the pull diagnostic model (textDocument/diagnostic). The change ensures that empty diagnostics are not published on document close when the client supports pull diagnostics.
Key Changes
- Added conditional check in
didClosemethod to skip publishing empty diagnostics whenclientSupportsPullDiagnosticsis true - Follows the same pattern already established in the
validatemethod
src/main/java/com/github/_1c_syntax/bsl/languageserver/BSLTextDocumentService.java
Show resolved
Hide resolved
|
@copilot что со сборкой? |
|
@copilot Завис? |
Co-authored-by: nixel2007 <[email protected]>
Head branch was pushed to by a user without write access
Added test coverage for the
|
src/test/java/com/github/_1c_syntax/bsl/languageserver/BSLTextDocumentServiceTest.java
Outdated
Show resolved
Hide resolved
Co-authored-by: nixel2007 <[email protected]>
|



didCloseinBSLTextDocumentServiceto checkclientSupportsPullDiagnosticsbefore publishing empty diagnosticsdidClosePublishesEmptyDiagnosticsWhenClientDoesNotSupportPullDiagnostics()- verifies publishEmptyDiagnosticList is called when client doesn't support pull diagnosticsdidCloseDoesNotPublishEmptyDiagnosticsWhenClientSupportsPullDiagnostics()- verifies publishEmptyDiagnosticList is NOT called when client supports pull diagnosticsclientCapabilitiesHolderdirectly instead of using event publishingOriginal prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.