Skip to content

Coalesce console output#742

Open
scramsby wants to merge 1 commit into
MisterTea:masterfrom
scramsby:scramsby-coalesce
Open

Coalesce console output#742
scramsby wants to merge 1 commit into
MisterTea:masterfrom
scramsby:scramsby-coalesce

Conversation

@scramsby
Copy link
Copy Markdown
Contributor

The ET client wrote each received TERMINAL_BUFFER packet to stdout individually. When the server sent a burst of output (e.g. a tmux session switch redrawing multiple panes), each packet became a separate write() to the local terminal, causing the terminal emulator to render intermediate states (screen-clear in one frame, repaint in the next) — producing visible flicker.
Fix: accumulate all TERMINAL_BUFFER payloads received in a single select() wake into one string, then write once after draining the packet queue.

To test:
Connect to Linux machine from Windows machine using ET.
Switch between tmux sessions with sidebar panes — verify no flicker and no partial screen erasure.

The ET client wrote each received TERMINAL_BUFFER packet to stdout
individually. When the server sent a burst of output (e.g. a tmux
session switch redrawing multiple panes), each packet became a
separate write() to the local terminal, causing the terminal emulator
to render intermediate states (screen-clear in one frame, repaint in
the next) — producing visible flicker.
Fix: accumulate all TERMINAL_BUFFER payloads received in a single
select() wake into one string, then write once after draining the
packet queue.
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 1, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.90%. Comparing base (ddf67a5) to head (483028f).
⚠️ Report is 2 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #742      +/-   ##
==========================================
- Coverage   86.95%   86.90%   -0.06%     
==========================================
  Files          70       70              
  Lines        5282     5284       +2     
  Branches      490      491       +1     
==========================================
- Hits         4593     4592       -1     
- Misses        689      692       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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