Claude Code v2.1.330 ·
Sign-in explains when ANTHROPIC_PROFILE would make it pointless
With ANTHROPIC_PROFILE set, Claude Code refuses a Console sign-in that would create an API key and warns about Claude account sign-ins
You'll noticeTier: how much it should matter to you
2Useful: my rating, 1 to 5
1Signal: worth watching, 1 to 5
AuthArea: what it touches
ImprovementsKind: in v2.1.330,
ImprovementsSection of the release
What
ANTHROPIC_PROFILE is an environment variable (a setting passed in from your shell) naming the Anthropic profile to sign in with. When it is set:
- A Console sign-in that would create an API key is not started. Claude Code tells you to run
ant auth login --profile <name> or to unset the variable.
- Signing in with a Claude account shows a warning that Claude Code won't use that sign-in until you unset the variable and restart.
The sign-in screen now offers a way to go back to the login options in place of retrying.
Why
With a profile set, these sign-ins would be quietly ignored. You now get a clear message saying what to do instead.
What the documentation says
See this entry in the whole of v2.1.330 →