Repository navigation
Conversation
Collaborator
✅ Integration test reportCommit: 50020e8
Top 45 slowest tests (at least 2 minutes):
|
Contributor
Author
|
/review |
pietern
force-pushed
the
pietern/charm-v2/01-termtest-emulator
branch
from
November 18, 2026 13:07
732780f to
2f74a7b
Compare
pietern
force-pushed
the
pietern/charm-v2/01-termtest-emulator
branch
from
November 18, 2026 15:55
2f74a7b to
2b3ac00
Compare
bubbletea v2's cell renderer moves and edits cells with REP, ECH, ICH, DCH, IRM, IL/DL, SU/SD, DECSTBM, RI and tab stops. The emulator now handles them, ignores prefixed and intermediate CSIs (kitty keyboard, modifyOtherKeys, DECRQM), and maps LF to column 0 the way v2 expects when its input is not a TTY (off Windows). Scrolls and cell shifts keep the styles grid aligned with the text. Esc disambiguation is 100 ms. v2's reader holds a lone Esc for ultraviolet's 50 ms timeout, which starts when the byte is read. No v1 golden changes. Co-authored-by: Isaac <no-reply@databricks.com>
pietern
force-pushed
the
pietern/charm-v2/01-termtest-emulator
branch
from
November 18, 2026 16:07
2b3ac00 to
50020e8
Compare
Contributor
Author
|
/review |
There was a problem hiding this comment.
Automated review at 50020e8. Each finding was verified against the code.
Not ready yet: part of the automated review did not complete.
This test-only PR teaches the termtest terminal emulator the escape sequences bubbletea v2's cell renderer emits (REP, ECH, ICH, DCH, IRM, IL/DL, SU/SD, DECSTBM, RI, tab stops) and makes LF map to column 0 by default off Windows. The new sequences are well-tested, the scroll/cell helpers are cleanly factored, and the prefixed-CSI guard closes a real misparse. No production code is touched and no issues survived verification.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
Test-only. The termtest emulator (
libs/cmdio/cmdiotest/termtest) learns the sequences bubbletea v2's cell renderer emits: REP, ECH, ICH, DCH, IRM, IL/DL, SU/SD, DECSTBM, RI and tab stops. It ignores prefixed and intermediate CSIs (kitty keyboard, modifyOtherKeys, DECRQM), soCSI > 1 uis no longer read as restore-cursor. Scrolls and cell shifts keep the styles grid aligned with the text.LF returns to column 0 when the emulator maps newlines. That follows what bubbletea v2 assumes when its input is not a TTY, except on Windows. termtest now only turns the mapping on (
MapNewline), so the default stays on off Windows.Esc disambiguation is 100 ms (was 20 ms). v2's reader holds a lone Esc for ultraviolet's 50 ms timeout, from when the byte is read.
Why
The v2 swap (last PR in this stack) moves the pins' terminal output to bubbletea v2's cell renderer. The emulator has to understand those sequences before the goldens can show a v2 diff that means something. This PR changes no production code and no golden.
Tests
go build ./..., golangci-lint onlibs/cmdio/..., gofmt.TERM=xterm-256color go test -race -count=3 ./libs/cmdio/....-update. No golden changes.Stack: this PR is based on the pins branch
pietern/termtest-pins(termtest capabilities and the v1 pin tests), which sits on #7688. Merge order: #7688,pietern/termtest-pins, then this PR and the stack above it.Manual checks for real terminals: none for this PR.
This pull request and its description were written by Isaac.