Repository navigation
fix: filter 'quickfix' code action for IJ intention - #218
Merged
fbricon merged 1 commit intoApr 16, 2024
Merged
Conversation
fbricon
reviewed
Apr 16, 2024
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #218 +/- ##
========================================
Coverage 18.98% 18.99%
========================================
Files 232 232
Lines 7807 7804 -3
Branches 1435 1059 -376
========================================
Hits 1482 1482
+ Misses 6062 6059 -3
Partials 263 263 ☔ View full report in Codecov by Sentry. |
Signed-off-by: azerr <[email protected]>
angelozerr
force-pushed
the
filter_quickfix_codeaction
branch
from
April 16, 2024 08:17
bce6ec8 to
d4e5344
Compare
Contributor
|
thanks @angelozerr! |
angelozerr
pushed a commit
that referenced
this pull request
Oct 27, 2026
…pose (#1776) * fix: close a server connection that a start opens after a stop or dispose LanguageServerWrapper.start() creates the connection on a pooled thread. A stop or a dispose while it did, or before the start, as when a document connects late, found no connection to close, and the start then opened it. A dispose also cancels the rest of the start, so its error handler, which stops the connection, is skipped. Nothing closed the connection: the language server's process kept running, or, in tests, the mock language server's thread which reads the connection, as LanguageServerFileEnablementTest reported on macOS: Thread leaked: Thread[#218,pool-3-thread-2,5,main] (alive) RUNNABLE at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.listen Once the connection is started, the start now checks, under the wrapper's lock, whether the language server was disposed or this start was stopped, and if so closes the connection itself. Tests: LanguageServerWrapperDisposeWhileStartingTest. A dispose while the connection is created, and a start after a dispose, close the connection, the second before the start's error notification; both fail without the change. ./gradlew test: 831 tests, 3 skipped, and the 7 macOS-only failures main has. * test: let the mock connection be stopped from two threads at once After CodeRabbit's review: a stop while a language server starts can now stop its connection twice, from the stop's thread and from the start's, which closes the connection it opened after the stop. The connection providers of LSP4IJ allow it: OSProcessStreamConnectionProvider synchronizes stop() and ignores a second one, and ProcessStreamConnectionProvider only destroys its process. But MockConnectionProvider.stop() iterates and clears a plain list, and two stops at once could throw, which would leave the server stopping. MockConnectionProvider.start() and stop() now take turns. Tests: LanguageServerWrapperDisposeWhileStartingTest gains a stop, not a dispose, while the connection is created, which closes the connection; it fails without the check of the start's context. ./gradlew test: 832 tests, 3 skipped, and the 7 macOS-only failures main has.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
fix: filter 'quickfix' code action for IJ intention