Skip to content

feat(repl): blank-line gutter between the submitted prompt and model output - #206

Merged
justrach merged 2 commits into
mainfrom
fix/prompt-output-gutter
Jul 15, 2026
Merged

feat(repl): blank-line gutter between the submitted prompt and model output#206
justrach merged 2 commits into
mainfrom
fix/prompt-output-gutter

Conversation

@justrach

Copy link
Copy Markdown
Owner

After Enter, readline wrote a single CRLF so the model's first output line butted
directly against the submitted prompt, making it hard to see where the response
started. It now emits a second newline so there is a clear blank-line gutter.

Test

scripts/test-pty-gutter.py drives the real REPL in a pseudo-terminal, submits a
local /help, and asserts the rendered transcript has a blank line immediately
before the command output. Anchored on the output line (robust to echo-redraw
timing) and rendered rather than raw (independent of ONLCR). Deterministic across
repeated runs; the existing scripts/test-pty-repl.py still passes.

Scope

TUI half only. Per the TUI-first rule the GUI transcript renderer needs the same
gutter to not diverge — tracked in #205, which stays open for that mirror.

Refs #205

justrach and others added 2 commits July 14, 2026 09:47
…output

After Enter, readline wrote a single CRLF so the model's first output line
butted directly against the submitted prompt, making it hard to see where the
response started. Emit a second newline so there is a clear blank-line gutter.

TUI half only; the GUI transcript renderer needs the same gutter to not
diverge (tracked in #205).

Co-Authored-By: blackfloofie <265516171+blackfloofie@users.noreply.github.com>
Drives the real REPL in a pseudo-terminal (reusing scripts/pty_harness.py),
submits a local /help, and asserts the rendered transcript has a blank line
immediately before the command output — the gutter added in 2bf68dd. Anchored on
the output line (not a fixed index) and rendered rather than raw, so it's robust
to echo-redraw timing and ONLCR. Deterministic across repeated runs; the existing
scripts/test-pty-repl.py still passes against the same binary.

Co-Authored-By: blackfloofie <265516171+blackfloofie@users.noreply.github.com>
@justrach
justrach merged commit b519a0c into main Jul 15, 2026
6 checks passed
@justrach
justrach deleted the fix/prompt-output-gutter branch July 15, 2026 10:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant