[BUG] "Paste code here" field pre-fills with stale/unrelated text across multiple login flows (login, setup-token, design-login) — WSL2

Open 💬 0 comments Opened Jul 6, 2026 by dandreas69

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

<img width="1160" height="337" alt="Image" src="https://github.com/user-attachments/assets/85f527d6-8ff8-4635-bcb5-934f8d7df3d7" />
<img width="1846" height="779" alt="Image" src="https://github.com/user-attachments/assets/e81f3131-3888-4e4a-a8a7-caa1c71f05fa" />

Environment:

  • OS: Windows 11 with WSL2 (Ubuntu)
  • Claude Code version: v2.1.201
  • Terminal: Windows Terminal (also reproduced in Arc and Chrome browser windows

during the OAuth step)

  • Account type: Claude subscription (paying customer)

Summary:
The "Paste code here if prompted >" input field, shown during OAuth login flows,
does not correctly accept the authorization code copied from the browser. Instead,
it pre-fills with unrelated leftover text: in different attempts, this included
output from a prior npm command, the full OAuth authorization URL duplicated back
into the field, and long strings of repeated characters (asterisks, "c" characters).

This happened across three separate login flows in the same session:

  1. Standard /login
  2. claude setup-token
  3. /design-login (a separate design-system authorization prompt)

What Should Happen?

Expected behavior:
The field should be empty and ready to accept the actual authorization code from
the browser, or auto-fill correctly with that code if the flow supports auto-capture.

Actual behavior:
The field pre-fills with unrelated text unconnected to the current login attempt.
This happened consistently across multiple attempts and multiple different login
flows, ruling out a one-off clipboard issue. Manual character-by-character typing
was not a practical workaround given the code length.

Impact:
Unable to authenticate Claude Code at all during this session, despite an active
paid subscription. Had to switch to a different tool to continue work.

Additional notes:
This does not appear to be a clipboard sync issue between Windows and WSL2, since
the pre-filled text was demonstrably NOT what had been copied at the time (e.g.
old command output appearing instead of a freshly copied URL).

Error Messages/Logs

Steps to Reproduce

  1. Run claude (or /login, or claude setup-token) in a WSL2 terminal.
  2. Press "c" to copy the printed OAuth URL, or let the browser open automatically.
  3. Complete authorization in the browser.
  4. Attempt to enter the resulting code into the "Paste code here if prompted >"

field, either by pasting or by the field auto-populating.

Claude Model

Opus

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

2.1.201

Platform

Anthropic API

Operating System

Ubuntu/Debian Linux

Terminal/Shell

WSL (Windows Subsystem for Linux)

Additional Information

_No response_

View original on GitHub ↗