🐞 Language Server Requests Should Timeout
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 25/100
Direzione di ricerca
Inizia individuando la gestione delle richieste al language server e dell’arresto in CodeEdit, quindi riproduci il problema con il binario sourcekit-lsp fornito con Xcode 16. Definisci il comportamento del timeout per le richieste ordinarie, di lunga durata e immediate; il lavoro è completato quando le richieste non restano più in attesa indefinitamente e il caso di uscita consente di terminare.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Description
There is a chance that language servers (maliciously or due to a bug) may not respond to requests made by the client (CodeEdit). This can cause problems, for example:
- Memory build up as syntax token requests pile up with no responses.
- App refusing to quit before the language server exits, but the language server does not respond to the
exitmessage. - UI hanging forever after a request (eg for a definition search).
In each of these cases one solution would be to time out the request. I think our LSP requests should have a default timeout length.
This has the caveat for requests that may take a long time. Those requests will need to be overridable so they can take longer. The same goes for requests that need immediate response (like the exit message), which will need to be shorter.
To Reproduce
The sourcekit-lsp binary that ships with Xcode 16 is bugged, and will not respond to the exit message. This leaves CodeEdit hanging when quitting the app and requires a force quit.
The same LSP does not respond to semantic token requests (despite declaring the capability, this is a bug with sourcekit-lsp). This may cause cached request handlers to build up over time.
Expected Behavior
Each language server request should have a timeout parameter. This likely means creating a new LanguageServer connection type that passes messages through to another type, but provides a timeout handler for requests. This may be something we can contribute back to the LanguageServer package.
Version Information
CodeEdit: 0.3.3
Additional Context
No response
Screenshots
No response
- Lingua principale
- Swift
- Stelle
- 23k
- Fork
- 1.2k
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di CodeEditApp/CodeEdit
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
CodeEditApp/CodeEdit#2190 ·
-
Is this project dead? Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 15/100
CodeEditApp/CodeEdit#2195 · 5 reazioni ·
-
enhancement
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
CodeEditApp/CodeEdit#2185 ·
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
CodeEditApp/CodeEdit#2181 ·
-
creashes on starting Apertabug
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
CodeEditApp/CodeEdit#2180 ·
Tutte le issue di CodeEditApp/CodeEdit
Issue simili
-
The correction-threshold rationale says 17 restraint cases collide; the current corpus has 16 Apertaarea:dictation documentation P2
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
uttrflow/uttrflow-swift#1180 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
OneBusAway/onebusaway-ios#1451 ·
-
enhancement
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100