Clipboard paste on WSL only tries powershell.exe; the Linux clipboard fallback is unreachable, so paste breaks when Windows interop is disabled

Status Open
Reported on v2.1.220
Maintainer reply None cached
Activity 0 comments · opened Jul 31, 2026

What happens: In Claude Code 2.1.220 on WSL2, pressing Ctrl+V reports "No image found in clipboard" (and text paste fails too) when the WSL distro has [interop] enabled=false in /etc/wsl.conf.

Why: The clipboard code detects WSL and routes every clipboard read/write to powershell.exe. The code has a fallback path for Linux clipboard tools (wl-paste etc.), but on WSL that branch can never be reached — so if interop is off and powershell.exe doesn't exist, paste is fully broken even though WSLg's Wayland clipboard bridges to Windows and wl-paste works fine in the same terminal.

Additionally, the image-paste path calls wl-paste asking only for image/png, while WSLg offers Windows screenshots as image/bmp only — so even with wl-paste available, screenshot paste fails without a bmp-to-png conversion.

Suggested fix: On WSL, fall back to the Linux clipboard tools when powershell.exe is unavailable, and accept image/bmp (converting to PNG) when reading images.

Context: We run Claude Code inside a locked-down WSL distro with interop deliberately disabled (a sandbox for beginner learners). We've worked around it with a shim, but the fallback code already exists in the binary — it's just unreachable.

Environment: Claude Code 2.1.220, WSL2 (Ubuntu), Windows 11, [interop] enabled=false in /etc/wsl.conf, WSLg available (wl-paste/wl-copy working).

View original on GitHub ↗