llvm / llvm/llvm-project

[lldb][windows] The ConPTY interlaces VT sequences in the debuggee's output

Open
#183,362 1 comment 1 reaction 1 assignee Claimed by @charles-zablit View on GitHub
lldb platform:windows
Dominant language
LLVM
Stars
40.5k
Forks
18.7k
PR merge metrics
PR metrics pending

Description

The ConPTY being a terminal emulator rather than a simple pipe, it means that we get VT sequences interlaced in the debuggee's output which mimic the limitations of a terminal.

If the terminal is 80x25 (the default) and the program emits a line longer than 80 characters, the ConPTY emits a VT sequence to reset the position of the cursor to the beginning of the next line.

This is problematic for lldb because it results in the output of programs being mangled and overwriting the `(lldb)` prompt and previous command outputs.

We have to use a ConPTY instead of simple pipe because we want to be able to debug TUI programs which might rely on the output/input being a console.

This issue is to track the progress of handling VT sequences correctly.

cc: @Nerixyz

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.