Skip to content

fix(tui): scroll transcript with PageUp/PageDown while composer is focused - #4991

Open
PiedPiper911 wants to merge 4 commits into
bytedance:mainfrom
PiedPiper911:fix/tui-pageup-pagedown-scroll-4974
Open

fix(tui): scroll transcript with PageUp/PageDown while composer is focused#4991
PiedPiper911 wants to merge 4 commits into
bytedance:mainfrom
PiedPiper911:fix/tui-pageup-pagedown-scroll-4974

Conversation

@PiedPiper911

@PiedPiper911 PiedPiper911 commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

PageUp/PageDown now scroll the transcript while the composer stays focused (the composer keeps focus), and transcript refreshes preserve the user's scroll position when they have scrolled away from the bottom — follow resumes only once they return to the bottom. Fixes #4974.

Surface area

  • Frontend UI — TUI keybindings and scroll-follow behavior
  • Backend API
  • Agents / LangGraph
  • Sandbox
  • Skills
  • Dependencies
  • Default behavior change
  • Docs / tests / CI only

Screenshots / Recording

N/A — terminal UI change; no visual diff to attach from this environment.

Bug fix verification

  • Test path that reproduces the bug: backend/tests/test_tui_app.py::test_pageup_pagedown_scroll_transcript_while_composer_focused and ::test_refresh_transcript_preserves_scroll_position_when_scrolled_up — the first presses PageUp/PageDown while the composer is focused and asserts the transcript scrolls; the second asserts a streamed refresh does not snap the user back to the bottom.
  • Did it go red on main and green on this branch? The new tests encode the previously-broken behavior (before the fix, PageUp/PageDown were not routed to #scroll and _refresh_transcript always called scroll_end); they pass on this branch. I did not run them against main in this environment.
  • Full suite: pytest tests/test_tui_app.py — 20 passed.

Validation

Backend: pytest tests/test_tui_app.py (20 passed) + py_compile on the changed files. Not run here: make lint / the full backend suite (sandbox limits).

AI assistance

Tool(s) used: WorkBuddy (AI coding assistant)

How you used it: AI implemented the fix and the two tests from the issue's reproduction notes; I reviewed every line of the diff and ran the test suite.

  • I've read and understand every line of this change and take responsibility for it — it's not unreviewed AI output.

@CLAassistant

CLAassistant commented Aug 24, 2026

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 2 committers have signed the CLA.

✅ PiedPiper911
❌ Wu Renliang


Wu Renliang seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@github-actions github-actions Bot added risk:medium Medium risk: regular code changes size/M PR changes 100-300 lines labels Aug 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk:medium Medium risk: regular code changes size/M PR changes 100-300 lines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[bug] TUI PageUp/PageDown do not scroll transcript while composer is focused

2 participants