Fix Python client timeout unit and disconnect handling - #9
Merged
Conversation
unp1
force-pushed
the
fix/python-client-stability
branch
from
June 22, 2026 18:01
0e5308d to
97d5ef8
Compare
The test pre-loaded a response before the request was registered, so the reader could deliver it before callSync registered its waiting future; the handler then NPE'd and callSync blocked forever (no timeout). It is an artificial scenario and is covered deterministically by the client-stability PR's callSync test. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
unp1
force-pushed
the
fix/python-client-stability
branch
from
June 22, 2026 18:24
97d5ef8 to
366a372
Compare
unp1
force-pushed
the
fix/client-test-compilation
branch
from
June 22, 2026 18:49
ff41056 to
61e6d2f
Compare
wadoon
approved these changes
Jun 22, 2026
This was referenced Jun 23, 2026
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.
Python client stability (
keyext.client.python):LspEndpoint'stimeout=2000is seconds in Python (≈33 min), not the milliseconds the literal suggests. Naively changing it to2.0would abort long-running KeY proofs. Instead the default is nowNone(wait indefinitely), documented as seconds when set.call_methodfails fast withConnectionErrorinstead of hanging forever.Tests:
tests/test_lsp_endpoint.pycovers the default, a finite (seconds) timeout, and the disconnect-wakeup (the latter two fail on the old code).Notes:
mainonce it merges.LspEndpointas Fix byte-based JSON-RPC framing and request-id race (Python client) #5, but the request-id lines are left untouched so the two merge cleanly;tests/__init__.pyis a trivial identical add in both.PR has been created with AI tooling