Wrapped links leak OSC 8 escape markup in Ghostty
Nadie ha tomado este issue todavía.
- Lenguaje dominante
- Shell
- Estrellas
- 11.2k
- Forks
- 1.9k
- Merge medio
- 14 h 16 min
- PR fusionados (30 d)
- 6
Descripción
Describe the bug
Long links in assistant Markdown sometimes render with the OSC 8 hyperlink control payload visible as text when the link wraps in Ghostty. The output is prefixed with text resembling:
]8;;id=md-<generated-id>;https://example.com/a/very/long/path/https://example.com/a/very/long/path/
The saved assistant response contains only a valid plain URL, with no malformed Markdown or escape sequences. This indicates the corruption occurs in Copilot CLI's terminal rendering rather than in model output.
This appears related to the 1.0.68 changelog fix, "Preserve wrapped OSC 8 hyperlink IDs in terminal output," but still reproduces on 1.0.78.
Affected version
GitHub Copilot CLI 1.0.78
Steps to reproduce the behavior
- Launch Copilot CLI in Ghostty.
- Have an assistant response end with a bare URL long enough to wrap at the current terminal width.
- Observe that the URL is preceded by visible OSC 8 payload text such as
]8;;id=md-...;and may appear duplicated.
An affected session is:
250a0930-cde5-4f39-bcdd-c40ef05656a0
The problem is visible in the final assistant response of that session.
Expected behavior
The response should display one clean, clickable URL. OSC 8 control sequences and generated hyperlink IDs must never be visible, including when the URL wraps across terminal lines.
Additional context
- Operating system: macOS (Darwin), Apple Silicon
- Terminal: Ghostty
1.3.2-main-+8252871b2 - Environment:
TERM_PROGRAM=ghostty,TERM=xterm-ghostty,COLORTERM=truecolor - Workaround: launching with
FORCE_HYPERLINK=0 copilotprevents OSC 8 hyperlinks from being emitted - The local session event log records the assistant content as normal prose followed by a plain URL, confirming the malformed text is introduced during rendering
- Screenshot exists locally but was not attached because
gh issue createdoes not support uploading issue-form attachments
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Línea de trabajo
Reproduce el problema ejecutando Copilot CLI 1.0.78 en Ghostty con una URL larga sin formato que se ajusta en varias líneas, usando la sesión 250a0930-cde5-4f39-bcdd-c40ef05656a0 como contexto. Compara la URL sin formato del registro de eventos de la sesión con la salida del terminal y sigue la ruta de renderizado de OSC 8; se considera terminado cuando los enlaces ajustados se muestran como una única URL limpia en la que se puede hacer clic, sin cargas de control visibles ni texto duplicado.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Área
- cli
- Tipo de issue
- Error
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Estado de actividad
- Tranquilo
- Claridad
- Bastante claro
- Aptitud para principiantes
- 48/100