Terminal auto-scrolls to very top (oldest output) when trying to scroll up while agent is working

Resolved 💬 3 comments Opened Oct 31, 2025 by mkreyman Closed Oct 31, 2025

Bug Description

When Claude Code agent is actively working and outputting to the terminal, attempting to scroll up to review recent command history immediately causes the terminal to jump to the very top of the terminal session (the oldest output from when the terminal started). This makes it impossible to review recent commands or output while the agent is still running.

Steps to Reproduce

  1. Start a task that generates continuous terminal output (e.g., running tests, building, or any multi-step agent task)
  2. While the agent is still working and outputting text, try to scroll up in the terminal to see recent history
  3. The terminal immediately jumps to the very top of the entire terminal session (oldest output)

Expected Behavior

The terminal should maintain the scroll position when the user manually scrolls up, allowing review of recent history even while new output is being generated.

Current Behavior

Terminal forcibly jumps to the very top (oldest output) every time you try to scroll up, making it impossible to review recent history during agent execution.

Impact

This severely impacts the ability to:

  • Review recent command outputs while agent is working
  • Compare current output with previous results
  • Debug issues by reviewing earlier steps
  • Basically ANY attempt to scroll up is immediately defeated

Environment

  • OS: macOS (Darwin 24.6.0)
  • Claude Code version: 2.0.31

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗