claude-code - 💡(How to fix) Fix [BUG] WSL2 text paste regression: Ctrl+V / right-click / Shift+Insert all fail in TUI input, worked in earlier version

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

All text paste methods fail in the Claude Code TUI input field on WSL2. This is a regression — the user reports it worked correctly in an earlier version of Claude Code. Other CLIs in the exact same WSL2 environment (Codex CLI, AGY CLI) paste normally.

Error Message

All three paste methods are silently swallowed — nothing is inserted. No error message.

Root Cause

  • Not a terminal issue: Codex CLI and AGY CLI paste correctly in the same WSL2 terminal session
  • Regression: User confirms paste worked in an older Claude Code version
  • All methods fail: Ctrl+V, right-click (QuickEdit mode is on), and Shift+Insert all produce no input
  • Root cause hypothesis: Claude Code's custom TUI input box intercepts/consumes keyboard and mouse events before they can insert clipboard content; other CLIs use standard readline which does not intercept these events

Fix Action

Workaround

None available. powershell.exe Get-Clipboard > /tmp/paste.txt can retrieve clipboard content but requires leaving the input field.

RAW_BUFFERClick to expand / collapse

Description

All text paste methods fail in the Claude Code TUI input field on WSL2. This is a regression — the user reports it worked correctly in an earlier version of Claude Code. Other CLIs in the exact same WSL2 environment (Codex CLI, AGY CLI) paste normally.

Steps to Reproduce

  1. Open a WSL2 session (Ubuntu 24.04) in the default Windows console (not Windows Terminal)
  2. Launch claude (Claude Code CLI)
  3. Copy any text to clipboard (Windows clipboard)
  4. At the input prompt, attempt to paste using any of:
    • Ctrl+V
    • Right-click
    • Shift+Insert

Expected Behaviour

Text from the clipboard should be inserted into the Claude Code input field, as it does in other CLIs using the same terminal.

Actual Behaviour

All three paste methods are silently swallowed — nothing is inserted. No error message.

Key Observations

  • Not a terminal issue: Codex CLI and AGY CLI paste correctly in the same WSL2 terminal session
  • Regression: User confirms paste worked in an older Claude Code version
  • All methods fail: Ctrl+V, right-click (QuickEdit mode is on), and Shift+Insert all produce no input
  • Root cause hypothesis: Claude Code's custom TUI input box intercepts/consumes keyboard and mouse events before they can insert clipboard content; other CLIs use standard readline which does not intercept these events

Environment

  • OS: Windows + WSL2 (Ubuntu-24.04), kernel 6.6.87.2-microsoft-standard-WSL2
  • Claude Code version: 2.1.165 (also reproduced on 2.1.163)
  • Installation: Native binary at ~/.local/share/claude/versions/2.1.165
  • Terminal: Default Windows console (legacy conhost), WT_SESSION is empty, TERM_PROGRAM is empty
  • TERM: xterm-256color
  • Shell: bash
  • Node.js: v24.14.1
  • Display: WSLg active (DISPLAY=:0, WAYLAND_DISPLAY=wayland-0)

Comparison with Working CLIs

CLIPaste methodResult
Claude Code 2.1.165Ctrl+V❌ no input
Claude Code 2.1.165Right-click❌ no input
Claude Code 2.1.165Shift+Insert❌ no input
Codex CLICtrl+V✅ works
AGY CLICtrl+V✅ works

Workaround

None available. powershell.exe Get-Clipboard > /tmp/paste.txt can retrieve clipboard content but requires leaving the input field.

Additional Notes

Because this is a confirmed regression, bisecting to the exact version that introduced the break would help narrow down the commit. The user is willing to test specific versions if needed.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING