mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-06-21 10:22:18 +00:00
fix(cli): default cli_refresh_interval to 1.0 to keep status bar alive (#49087)
PR #49056 set the default to 0, which reverts the #45592 idle-clock fix: without a periodic invalidate, prompt_toolkit stops repainting the bottom chrome during idle and the status bar goes stale/disappears after a turn. Restore 1.0 as the default for everyone. The config knob stays — users on emulators where the per-second redraw fights auto-scroll (#48309) can set display.cli_refresh_interval: 0 to opt out.
This commit is contained in:
parent
2dd285f9b3
commit
d7bff949af
2 changed files with 14 additions and 11 deletions
|
|
@ -1582,11 +1582,13 @@ DEFAULT_CONFIG = {
|
|||
# spinner), or ascii. Live-swappable via `/indicator <style>`.
|
||||
"tui_status_indicator": "kaomoji",
|
||||
# Seconds between prompt_toolkit redraws in the classic CLI when idle.
|
||||
# 0 = disabled (no background refresh — the pre-0.15.2 behaviour).
|
||||
# Positive values e.g. 1.0 keep wall-clock status-bar read-outs
|
||||
# (idle-since-last-turn) ticking but may fight terminal auto-scroll in
|
||||
# non-fullscreen mode on some emulators (Xshell, iTerm2, etc.).
|
||||
"cli_refresh_interval": 0,
|
||||
# Default 1.0 keeps the wall-clock status-bar read-outs (idle-since-
|
||||
# last-turn) ticking and keeps the bottom chrome alive during idle —
|
||||
# without it prompt_toolkit stops repainting the status bar after a
|
||||
# turn and it can go stale/disappear (#45592).
|
||||
# Set 0 to disable the background refresh if it fights terminal
|
||||
# auto-scroll in non-fullscreen mode on some emulators (#48309).
|
||||
"cli_refresh_interval": 1.0,
|
||||
"user_message_preview": { # CLI: how many submitted user-message lines to echo back in scrollback
|
||||
"first_lines": 2,
|
||||
"last_lines": 2,
|
||||
|
|
|
|||
|
|
@ -956,13 +956,14 @@ class TestInterimAssistantMessageConfig:
|
|||
|
||||
|
||||
class TestCliRefreshIntervalConfig:
|
||||
"""Test the CLI refresh_interval config default (#48309)."""
|
||||
"""Test the CLI refresh_interval config default (#45592 / #48309)."""
|
||||
|
||||
def test_default_config_disables_cli_refresh_interval(self):
|
||||
"""cli_refresh_interval defaults to 0 (disabled) to avoid
|
||||
background redraws that fight terminal auto-scroll-on-output
|
||||
in non-fullscreen mode (Xshell, iTerm2, Windows Terminal)."""
|
||||
assert DEFAULT_CONFIG["display"]["cli_refresh_interval"] == 0
|
||||
def test_default_config_enables_cli_refresh_interval(self):
|
||||
"""cli_refresh_interval defaults to 1.0 so the idle status-bar
|
||||
clock keeps ticking and the bottom chrome stays alive during
|
||||
idle (#45592). Users on emulators where the periodic redraw
|
||||
fights auto-scroll can set it to 0 (#48309)."""
|
||||
assert DEFAULT_CONFIG["display"]["cli_refresh_interval"] == 1.0
|
||||
|
||||
|
||||
class TestDiscordChannelPromptsConfig:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue