Summary
Successful Claude login can persist the Claude usage source as oauth, which disables the auto fallback path. If the current Claude CLI login reports success but CodexBar cannot read OAuth credentials afterward, the app can get stuck repeatedly asking for Claude credentials.
Local repro / observed behavior
Environment:
- CodexBar app: 0.41.0 (
/Applications/CodexBar.app, build commit 27cff88a1)
- Claude Code: 2.1.201
- macOS app install, default menu-bar flow
What I saw locally:
- CodexBar had Claude enabled with
source: "oauth" in ~/.config/codexbar/config.json.
- Running
codexbar --provider claude --format json --pretty returned:
Claude OAuth credentials not found. Run claude to authenticate.
- App logs included a keychain cache read failure for
oauth.claude.
- The menu-bar app kept asking for Claude credentials, even though Claude Code itself was installed and authenticated enough for CLI usage.
Workaround:
- Changing the Claude source in
~/.config/codexbar/config.json from oauth to auto, validating config, and restarting CodexBar stopped the credential prompt loop locally.
Suspected root cause
runClaudeLoginFlow() currently forces:
self.settings.claudeUsageDataSource = .oauth
after the login runner reports success.
That makes the app persist an OAuth-only state immediately after the setup flow. If CodexBar cannot read the OAuth credentials, it never gets to use the app's fallback behavior. Keeping the source on auto is less brittle: OAuth can still be preferred when readable, but CLI/Web fallback remains available when OAuth is not usable.
Related issues
Expected behavior
A successful Claude setup flow should leave CodexBar in a resilient source mode. Out of the box, login should not pin users to OAuth-only if Auto fallback is available and intended as the safer default.
Summary
Successful Claude login can persist the Claude usage source as
oauth, which disables theautofallback path. If the current Claude CLI login reports success but CodexBar cannot read OAuth credentials afterward, the app can get stuck repeatedly asking for Claude credentials.Local repro / observed behavior
Environment:
/Applications/CodexBar.app, build commit27cff88a1)What I saw locally:
source: "oauth"in~/.config/codexbar/config.json.codexbar --provider claude --format json --prettyreturned:Claude OAuth credentials not found. Run claude to authenticate.oauth.claude.Workaround:
~/.config/codexbar/config.jsonfromoauthtoauto, validating config, and restarting CodexBar stopped the credential prompt loop locally.Suspected root cause
runClaudeLoginFlow()currently forces:after the login runner reports success.
That makes the app persist an OAuth-only state immediately after the setup flow. If CodexBar cannot read the OAuth credentials, it never gets to use the app's fallback behavior. Keeping the source on
autois less brittle: OAuth can still be preferred when readable, but CLI/Web fallback remains available when OAuth is not usable.Related issues
Claude Code-credentialskeychain item holds onlymcpOAuthentries on Claude Code 2.1.x → ClaudeOAuthCredentialsError + hourly "delegated CLI refresh" opens the default browser #1844 fixed a related mcpOAuth/browser-launch path, but this looks narrower: the login flow itself persists the fallback-hostile source after success.Expected behavior
A successful Claude setup flow should leave CodexBar in a resilient source mode. Out of the box, login should not pin users to OAuth-only if Auto fallback is available and intended as the safer default.