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

v1.17.0 breaks Positron connections: single-quoted `--url` in ProxyCommand reaches the CLI literally ("Premature close")

Offen Anfängerfreundlich
#1,153 1 Kommentar 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Maintainer antworten meist innerhalb von 2 Tagen

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
2/5
Geschätzter Aufwand
1-3 Stunden
Anfängerfreundlichkeit
70/100
Issue-Typ
Bug
Klarheit
Klar beschrieben
Aktivitätsstatus
Aktiv
Tech-Stack
shell, typescript, vscode
Bereich
devtools

Rechercherichtung

Der Fehler liegt darin, wie die Erweiterung die ProxyCommand-Zeile in die generierte SSH-Konfiguration schreibt. Finde die Stelle, an der die Deployment-URL mit einfachen Anführungszeichen shell-gequotet wird, und vergleiche sie mit dem bestehenden Pfad-Quoting, von dem das Issue sagt, dass es bereits funktioniert. Prüfe, ob ein Unit-Test den generierten ProxyCommand-String abdeckt, und erweitere ihn um eine URL. Fertig ist, wenn die URL unverpackt oder in doppelte Anführungszeichen gesetzt ausgegeben wird, das bestehende Pfad-Quoting unverändert bleibt und der Test besteht.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

bug regression

Regression in v1.17.0; v1.16.4 works. Positron 1.134.0, macOS arm64, Coder v2.34.1.

Every Positron connection fails within ~100 ms:

[Trace] Spawning ProxyCommand: …/coder-darwin-arm64 --token= --url 'https://coder.example.com' --use-keyring=true ssh --disable-autostart --stdio …
[Error] Error resolving authority
Error [ERR_STREAM_PREMATURE_CLOSE]: Premature close

VS Code (Microsoft Remote-SSH) and plain ssh from a terminal work with the same generated config.

Cause

v1.17.0 POSIX-shell-quotes the URL in the ProxyCommand (--url 'https://…'); v1.16.4 wrote it bare. Positron's built-in open-remote-ssh doesn't run ProxyCommand through a shell: it tokenizes the ssh_config value (honoring double quotes only) and calls child_process.spawn(cmd, args). The CLI therefore gets the quotes literally and exits at flag parsing:

invalid argument "'https://coder.example.com'" for "--url" flag: parse "'https://coder.example.com'": first path segment in URL cannot contain colon

open-remote-ssh discards the child's stderr, so the user sees only "Premature close". Other editors built on open-remote-ssh are presumably affected the same way.

Workaround

Install v1.16.4 and turn off auto-update for the extension. There's no settings-level workaround: coder.sshConfig can't override ProxyCommand, and the conf file is rewritten on every connect.

Suggested fix

Quote the URL the way the paths already are (bare when it matches the safe character set, double quotes otherwise). Since 1.17.0 already rejects deployment URLs containing shell metacharacters, the single quotes don't add safety, and double quotes parse correctly in both OpenSSH and open-remote-ssh.

Vorherrschende Sprache
TypeScript
Sterne
132
Forks
48
Ø Merge
1 T. 20 Std.
Gemergte PRs (30 T.)
25

Entwicklungsumgebung

In Codespaces öffnen

Startet den Dev-Container des Projekts im Browser, mit Ihrem eigenen GitHub-Konto.

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 coder/vscode-coder

Alle Issues in coder/vscode-coder

Ähnliche Issues

Weitere Issues zu TypeScript

Neue Issues direkt in Ihr Postfach

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