CodexBar icon indicating copy to clipboard operation
CodexBar copied to clipboard

Could not parse Claude usage: Missing Current session

Open pvieito opened this issue 11 months ago • 20 comments

Since the fix for this issue, now CodexBar is not longer able to load the Claude Code usage with this error:

Could not parse Claude usage: Missing Current session

pvieito avatar Dec 26 '25 12:12 pvieito

true, just installed and not working

humblemuzzu avatar Dec 26 '25 13:12 humblemuzzu

can confirm this works as a workaround - open Safari or Chrome, log in to https://claude.ai, then check this Augment via web box. restart. all good

Image

aavetis avatar Dec 26 '25 13:12 aavetis

That is also not working for me:

Image

pvieito avatar Dec 26 '25 15:12 pvieito

I tried this an now getting this

Image

alexanderhupfer avatar Dec 27 '25 17:12 alexanderhupfer

It worked for me with this workaround.

wgsoft-de avatar Dec 28 '25 13:12 wgsoft-de

Currently as a workaround you can try these steps:

  1. Exit CodexBar (you can do killall CodexBar)
  2. Log out from all browsers (which provider fails)
  3. Log out from CLI (which provider fails)
  4. Open CLI of your provider and re-auth with Safari, enter credentials if necessary
  5. Open Settings -> Privacy & Security -> Full Disk Access, give access to CodexBar
  6. Open CodexBar

Let CodexBar sync and refresh, it should work, worked for me

Working provider with this workaround: Droid, Claude

https://github.com/steipete/CodexBar/issues/77#issuecomment-3695002256

dalisoft avatar Dec 28 '25 19:12 dalisoft

also encountered the same issue. it resulted in a claude process consuming 100% CPU usage + fans spinning like craycray (which is how I discovered the problem)

stevensyp avatar Dec 29 '25 03:12 stevensyp

Fixed in https://github.com/steipete/CodexBar/pull/85

nicosuave avatar Dec 29 '25 06:12 nicosuave

:-(

tried https://github.com/steipete/CodexBar/issues/62#issuecomment-3695001866 and that did not work

codexbar usage --status --log-level trace
2026-01-07T18:05:44+0000 debug com.steipete.codexbar.claude-usage: [CodexBarCore] [claude-web] Safari cookies: trying /Users/phil/Library/Cookies/Cookies.binarycookies (-1 bytes)
2026-01-07T18:05:44+0000 debug com.steipete.codexbar.claude-usage: [CodexBarCore] [claude-web] Safari cookies: failed to read /Users/phil/Library/Cookies/Cookies.binarycookies: The file “Cookies.binarycookies” couldn’t be opened because there is no such file.
2026-01-07T18:05:44+0000 debug com.steipete.codexbar.claude-usage: [CodexBarCore] [claude-web] Safari cookies: trying /Users/phil/Library/Containers/com.apple.Safari/Data/Library/Cookies/Cookies.binarycookies (40367 bytes)
2026-01-07T18:05:44+0000 debug com.steipete.codexbar.claude-usage: [CodexBarCore] [claude-web] Found sessionKey in Safari
2026-01-07T18:05:44+0000 debug com.steipete.codexbar.claude-usage: [CodexBarCore] [claude-web] Found session key: sk-ant-<redacted>
2026-01-07T18:05:45+0000 debug com.steipete.codexbar.claude-usage: [CodexBarCore] [claude-web] Organizations API status: 200
2026-01-07T18:05:45+0000 debug com.steipete.codexbar.claude-usage: [CodexBarCore] [claude-web] Organization ID: <a correct id redacted>
2026-01-07T18:05:45+0000 debug com.steipete.codexbar.claude-usage: [CodexBarCore] [claude-web] Organization name: phil's Organization
2026-01-07T18:05:45+0000 debug com.steipete.codexbar.claude-usage: [CodexBarCore] [claude-web] Usage API status: 200
Error: Invalid response from Claude API.
Image

PhilETaylor avatar Jan 07 '26 18:01 PhilETaylor

Debugging through a proxy I see this response from claude API ttps://claude.ai/api/organizations//usage so maybe not a CodexBar issue might be a Claude being nuts issue and ClodexBar not interpreting this?

related reddit thread https://www.reddit.com/r/ClaudeAI/comments/1q6ljlq/anthropic_just_silently_got_rid_of_all_the_usage/

  "five_hour": null,
  "seven_day": null,
  "seven_day_oauth_apps": null,
  "seven_day_opus": null,
  "seven_day_sonnet": null,
  "iguana_necktie": null,
  "extra_usage": null
}```

PhilETaylor avatar Jan 07 '26 18:01 PhilETaylor

I'm experiencing this issue as well. Right now, my claude code status says Could not parse Claude usage: missing session data

I tried the following but it did not work

Currently as a workaround you can try these steps:

  1. Exit CodexBar (you can do killall CodexBar)
  2. Log out from all browsers (which provider fails)
  3. Log out from CLI (which provider fails)
  4. Open CLI of your provider and re-auth with Safari, enter credentials if necessary
  5. Open Settings -> Privacy & Security -> Full Disk Access, give access to CodexBar
  6. Open CodexBar

Let CodexBar sync and refresh, it should work, worked for me

Working provider with this workaround: Droid, Claude

Any ideas @steipete

nbbaier avatar Jan 07 '26 18:01 nbbaier

note, there is a claude issue with reporting usage - https://status.claude.com

Image

aavetis avatar Jan 07 '26 19:01 aavetis

yesterday the usage didn't even show up properly in their web ui. i inspected the XHR response and saw the same response as @PhilETaylor . today their web ui works. but codexbar doesn't show usage, alternating between No available fetch strategy for claude. or Could not parse Claude usage: Missing Current session. i'm on 0.17.0 version (currently latest). haven't tried any of above mentioned workarounds yet. my claude data source is set to OAuth API.

Debug ui "probe logs" (i removed the noise):

Safari cookies: trying ~/Library/Cookies/Cookies.binarycookies (-1 bytes)
Safari cookies: failed to read ~/Library/Cookies/Cookies.binarycookies: The file “Cookies.binarycookies” couldn’t be opened because there is no such file.
Safari cookies: trying ~/Library/Containers/com.apple.Safari/Data/Library/Cookies/Cookies.binarycookies (70532 bytes)
strategy=oauth
hasSessionKey=false
hasOAuthCredentials=true

OAuth source selected.

Fetch strategy attempts with Claude selected says claude.oauth (oauth) unavailable. I know for a fact I have OAuth working. CodexBar isn't picking up on it. Maybe related to ytd's change to their OAuth...

  • context: https://news.ycombinator.com/item?id=46549823

ferologics avatar Jan 09 '26 14:01 ferologics

Ok. I overwrote my keychain credentials with a token that only had user:inference scope. CodexBar needs user:profile scope to fetch usage stats from the API. Fix:

# Delete the limited token from keychain
security delete-generic-password -s "Claude Code-credentials"

# Re-authenticate with regular OAuth
claude
# then type /login and complete browser auth

After that, CodexBar picked up the new token (which has user:profile scope) and usage stats work again.

ferologics avatar Jan 09 '26 15:01 ferologics

Still having the issue on my side, Full Disk Access, fixed the problem after I restarted

riderx avatar Jan 20 '26 00:01 riderx

what @ferologics suggested above worked for me

# Delete the limited token from keychain
security delete-generic-password -s "Claude Code-credentials"

# Logout Claude from CLI

# Re-authenticate with regular OAuth
claude
# then type /login and complete browser auth

ksingh-scogo avatar Feb 17 '26 13:02 ksingh-scogo

@ksingh-scogo @ferologics thanks for the quick fix, that worked for me the first time i tried it 🥇

cancel-cloud avatar Feb 23 '26 08:02 cancel-cloud

What would everyone like to be done here? Better messaging? This is a Claude Code CLI issue and our code can just surface the issue.

ratulsarna avatar Feb 23 '26 10:02 ratulsarna

@ratulsarna better messaging would be great. I'd like to know if the issue is with CodexBar or upstream

redixhumayun avatar Mar 03 '26 23:03 redixhumayun

Thanks for the report. I’m going to close this as answered. The thread above points to the underlying cause: Claude credentials without the required user:profile scope can make CodexBar unable to fetch usage, and re-authenticating Claude with the normal login flow resolves it for affected users.

The remaining gap here is mostly better messaging about whether the problem is upstream Claude credentials vs CodexBar itself. If this still reproduces on the latest release after re-auth, please open a fresh issue with current version details and the exact error text.

ngutman avatar Apr 12 '26 09:04 ngutman