anthropics / anthropics/claude-code

[BUG] Windows CLI Auth Error - OAuth Session Expires Before Code Can Be Pasted

Offen
#92,639 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
area:auth bug platform:windows
Vorherrschende Sprache
Python
Sterne
145k
Forks
23.1k
PR-Merge-Kennzahlen
PR-Kennzahlen ausstehend

Beschreibung

### Preflight Checklist

- [x] I have searched [existing issues](https://github.com/anthropics/claude-code/issues?q=is%3Aissue%20state%3Aopen%20label%3Abug) 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?

I am in my local file and I tried to log in to Claude. I have already updated the versions and done .gitignore. But when I log in, Claude goes to Chrome and I authorize it. However, before and after I copy the Authentication Code, it displays an "Auth Error" which is why I can't paste the code there. Sometimes I am able to paste it quickly, but it still throws an "Auth Error" anyway.

### What Should Happen?

Login Successfully!

### Error Messages/Logs

```shell
Auth error.
```

### Steps to Reproduce

1. In a native Windows project directory, run claude auth login.
2. Chrome opens; successfully log into Claude Pro and hit Authorize.
3. Observe that PowerShell has already crashed with an Auth Error before or during the exact moment you copy-paste the verification code.

### Claude Model

None

### Is this a regression?

Yes, this worked in a previous version

### Last Working Version

v2.1.261

### Claude Code Version

v2.1.260 (Claude Code)

### Platform

Anthropic API

### Operating System

Windows

### Terminal/Shell

PowerShell

### Additional Information

_No response_

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Rechercherichtung

Reproduce on native Windows in PowerShell by running `claude auth login` and completing the browser authorization flow. Start by finding the CLI auth login/OAuth callback handling and any Windows-specific process or timeout behavior. Done means the code can be pasted and login completes successfully instead of showing `Auth error.`

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
powershell, python
Bereich
authentication, cli
Issue-Typ
Bug
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Aktiv
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
52/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.