hermes - 💡(How to fix) Fix feat: smooth terminal reflow on window resize (parity with opencode/Claude Code) [5 pull requests]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Root Cause

This issue is a tracking feature request that addresses the root cause. There are currently 34+ individual bug reports covering specific manifestations of this problem:

Fix Action

Fixed

RAW_BUFFERClick to expand / collapse

Problem

When resizing the terminal window, the classic CLI (non-TUI, Rich + prompt_toolkit based) does not reflow or re-render the conversation history to fit the new dimensions. This causes multiple visible artifacts:

  • Ghost/overlapping lines -- previous content remains at the old width
  • Broken table borders -- Rich tables are rendered at the stale width
  • Accumulated blank separator lines -- after each resize, extra blank lines pile up
  • Distorted scrollback -- when scrolling back through conversation history after a resize, formatting is misaligned
  • Status bar duplication -- the prompt/status area can appear as duplicate rows

In contrast, competitor tools handle this smoothly:

  • Claude Code -- uses full-screen alternate buffer with SIGWINCH-triggered complete re-render
  • Opencode -- recalculates layout on resize events, content reflows seamlessly
  • Both give an uninterrupted reading experience regardless of window size changes

Expected Behavior

Resizing the terminal should trigger a complete re-render of the entire conversation history and all active display elements (tables, messages, status bar) to fit the new viewport dimensions -- matching the smooth experience of opencode and Claude Code.

Additional Context

This issue is a tracking feature request that addresses the root cause. There are currently 34+ individual bug reports covering specific manifestations of this problem:

  • #22976 -- TUI: Terminal resize accumulates blank separator lines
  • #17975 -- CLI TUI renders blank lines after terminal resize
  • #23034 -- fix(tui): clear terminal on resize to prevent ghost separator lines
  • #24137 -- TUI composer/scrollbar jumps during streaming and terminal resize
  • #18449 -- Rapid terminal resize leaves corrupted glyphs
  • #17961 -- TUI resize causes ghost copies (same root as #5474)
  • #24017 -- persistent_output replay strips ANSI after resize
  • #19280 -- Status bar duplication and blank line flooding on macOS
  • #6766 -- Duplicated prompt rows after resize
  • #22999 -- Classic CLI resize clears startup banner
  • And many more...

A comprehensive reflow solution would resolve all of these individual bugs.

Environment

  • macOS 26.4.1
  • Terminal: default (also reproduced in various terminal emulators)
  • Hermes Agent version: latest (main branch)

Suggested Approach

Investigate implementing a SIGWINCH signal handler that triggers a full re-render of the CLI display buffer, possibly by:

  1. Capturing the current conversation state
  2. Clearing the screen
  3. Re-rendering all content at the new terminal dimensions
  4. Preserving scrollback position where possible

For the Ink-based TUI mode (--tui), leverage React's re-render cycle with proper viewport dimensions.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING