OAuth token revoked · Please run /login

Resolved 💬 1 comment Opened Jul 21, 2025 by dhatzige Closed Jul 22, 2025

Bug Description
Issue: Persistent "OAuth token revoked" error after Max 20x plan upgrade
Environment:
macOS with bash shell
Claude Code migrated to local installation (~/.claude/local/)
Max 20x plan subscription (upgraded from previous plan)
Problem:
Persistent "OAuth token revoked · Please run /login" error that continues after completing all standard troubleshooting steps.
Steps Already Attempted:
Multiple /logout and clean authentication attempts
Removed auth files: rm -rf ~/.config/claude-code/auth.json
Cleared macOS Keychain: security delete-generic-password -s "claude-code"
Complete config directory removal: rm -rf ~/.config/claude-code/
Terminal restarts and claude update
Migration to local installation with claude migrate-installer
Manual shell alias setup for bash
Verified installation with claude doctor
Current Status:
Claude Code launches successfully after local migration
Authentication prompt appears but OAuth process fails immediately
/bug command non-functional
Error persists despite complete credential reset
Suspected Cause:
Authentication state issue specific to Max 20x plan upgrade, where OAuth handoff between browser authorization and terminal session fails consistently.

Environment Info

  • Platform: darwin
  • Terminal: Apple_Terminal
  • Version: 1.0.56
  • Feedback ID:

Errors

[{"error":"Error: Command failed: security find-generic-password -a $USER -w -s \"Claude Code\"\nsecurity: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.\n\n    at genericNodeError (node:internal/errors:983:15)\n    at wrappedFn (node:internal/errors:537:14)\n    at checkExecSyncError (node:child_process:882:11)\n    at execSync (node:child_process:954:15)\n    at A7 (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:797:5848)\n    at file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:709:48013\n    at Q (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:609:14408)\n    at fY (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:709:45724)\n    at QK (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:709:44590)\n    at SB (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:709:50639)","timestamp":"2025-07-21T22:45:23.234Z"},{"error":"Error: ENOENT: no such file or directory, open '/proc/version'\n    at Module.readFileSync (node:fs:442:20)\n    at Object.readFileSync (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:615:7077)\n    at file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:615:8638\n    at Q (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:609:14408)\n    at kT4 (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:709:62815)\n    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)","timestamp":"2025-07-21T22:45:23.529Z"},{"error":"Error: Command failed: security delete-generic-password -a $USER -s \"Claude Code\"\nsecurity: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.\n\n    at genericNodeError (node:internal/errors:983:15)\n    at wrappedFn (node:internal/errors:537:14)\n    at checkExecSyncError (node:child_process:882:11)\n    at execSync (node:child_process:954:15)\n    at A7 (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:797:5848)\n    at Dn0 (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:709:49129)\n    at In0 (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:709:49001)\n    at iJA (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:1833:2567)\n    at s61.startOAuthFlow (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:1833:3733)\n    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)","timestamp":"2025-07-21T22:45:31.695Z"},{"error":"Error: Command failed: security find-generic-password -a $USER -w -s \"Claude Code\"\nsecurity: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.\n\n    at genericNodeError (node:internal/errors:983:15)\n    at wrappedFn (node:internal/errors:537:14)\n    at checkExecSyncError (node:child_process:882:11)\n    at execSync (node:child_process:954:15)\n    at A7 (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:797:5848)\n    at file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:709:48013\n    at Q (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:609:14408)\n    at fY (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:709:45724)\n    at QK (file:///Users/dimxatz/.claude/local/node_modules/@anthropic-ai/claude-code/cli.js:709:44590)\n    at SB (file:///Users/dimxatz/.claude/local/node_modules/@anthropic

Note: Error logs were truncated.

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗