High CPU render loop when terminal width is detected as very small

Resolved 💬 4 comments Opened Jan 31, 2026 by egmnklc Closed Jan 31, 2026

Version

Claude Code 2.1.27

Summary

Claude Code enters a high CPU (98-100%) infinite render loop when the terminal reports an abnormally small width (observed: 14 columns). The process becomes unresponsive and must be force killed.

Steps to Reproduce

  1. Open Claude Code in a terminal that reports a very narrow width (14 columns observed)
  2. Claude Code immediately starts continuous "High write ratio" render cycles after startup completes
  3. Process becomes unresponsive

Debug Log Evidence

2026-01-31T16:44:29.247Z [DEBUG] High write ratio: blit=384, write=740 (65.8% writes), screen=14x96
2026-01-31T16:44:29.336Z [DEBUG] High write ratio: blit=384, write=741 (65.9% writes), screen=14x96
2026-01-31T16:44:29.367Z [DEBUG] High write ratio: blit=384, write=631 (62.2% writes), screen=14x96
... (repeats indefinitely at ~100ms intervals)

The render loop starts immediately after startup, before any user input or API call.

Expected Behavior

  • Claude Code should gracefully handle narrow terminals
  • Should display a warning or minimum width requirement
  • Should not enter an infinite render loop consuming 100% CPU

Actual Behavior

  • Process consumes 98-100% CPU
  • No user interaction possible
  • Requires kill -9 to terminate

Environment

  • macOS Darwin 25.1.0
  • Terminal width reported as 14 columns (abnormally small)

View original on GitHub ↗

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