Hacktoberfest 2026: die Issues, die Maintainer für den Oktober markiert haben – offen und einsteigerfreundlich. Hacktoberfest-Issues durchsuchen

🐞 Language Server Requests Should Timeout

Offen
#1,976 1 Kommentar 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
5/5
Geschätzter Aufwand
Über eine Woche
Anfängerfreundlichkeit
25/100
Issue-Typ
Bug
Klarheit
Größtenteils klar
Aktivitätsstatus
Veraltet
Tech-Stack
swift
Bereich
devtools

Rechercherichtung

Beginne damit, die Behandlung von Language-Server-Anfragen und das Herunterfahren in CodeEdit zu lokalisieren, und reproduziere dann das Problem mit der in Xcode 16 enthaltenen sourcekit-lsp-Binärdatei. Definiere das Timeout-Verhalten für gewöhnliche, lang laufende und sofortige Anfragen; fertig bedeutet, dass Anfragen nicht mehr unbestimmt lange warten und der Exit-Fall das Beenden ermöglicht.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

bug language server
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 exit message.
  • 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

Vorherrschende Sprache
Swift
Sterne
23k
Forks
1.2k
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beitragsleitfaden

Beitragsleitfaden öffnen

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus CodeEditApp/CodeEdit

Alle Issues in CodeEditApp/CodeEdit

Ähnliche Issues

Weitere Issues zu Swift

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.