Statusline renders vertically (1 char/line) during startup in tmux

Resolved 💬 5 comments Opened Feb 20, 2026 by oria-ai Closed Apr 1, 2026

Bug

When starting a new Claude Code session in a tmux window, the statusline briefly renders one character per line (vertically) for ~1-2 seconds before correcting itself. This happens on every new conversation.

Root Cause

process.stdout.columns briefly returns 1 during the welcome-screen-to-REPL transition. The rendering code:

this.terminalColumns = stdout.columns || 80

Since 1 is truthy, it doesn't fall back to 80 — it uses width=1, so each character wraps to its own line.

Evidence

Captured via rapid-fire tmux capture-pane at 50ms intervals. tmux reports 163x37 the entire time — pane dimensions never change. The bug is inside Node's stdout.columns.

Frame 35 (~2.1s) — Welcome box renders correctly at full width ✅

╭─── Claude Code v2.1.49 ─────────────────────────────╮
│                           │ Recent activity          │
│     Welcome back oria!    │ 2s ago   i want to debug │
│                           │ ...                      │
╰──────────────────────────────────────────────────────╯

Frame 41 (~2.5s) — Statusline goes vertical ❌

  v
  2
  .
  1
  .
  4
  9
   
  |
   
  🧬
   
  O
  p
  u
  s
   
  4
  .
  6
   
  |
   
  c
  b
  1
  0
  b
  9
  e
  5

That's v2.1.49 | 🧬 Opus 4.6 | cb10b9e5 rendered with terminal width = 1.

Frame ~3s+ — Self-corrects after next render cycle ✅

Repro

  1. Run Claude Code inside tmux
  2. Create a new tmux window (prefix + c)
  3. Start claude in the new window
  4. Observe the statusline spread vertically for ~1-2 seconds during startup

Environment

  • Claude Code v2.1.49
  • tmux 3.3a
  • Node.js v20.20.0
  • Linux (WSL2) in Gitpod
  • Terminal: VS Code integrated terminal

Suggested Fix

Either:

  • Clamp minimum terminal width: Math.max(stdout.columns || 80, 40)
  • Debounce/defer the initial statusline render until columns stabilize
  • Re-read columns on first SIGWINCH after startup

View original on GitHub ↗

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