Repository navigation
Closed
Description
What happened
On the Usage page (Limits view, All environments), the Claude card showed a "Monthly spend" row with a bar for each Claude account (99% and 74% left). After I clicked the refresh button, the row disappeared. Session, Weekly, and Weekly · Fable stayed. The server still had the data: both Claude provider status caches held a monthly_spend window after the refresh.
Diagnosis
The hub read never produces a monthly spend window, and the client lets a newer hub read replace the native probe's windows as a whole.
apps/server/src/usage/cliproxyApi.ts(readAccount, Claude branch) builds theget_usage-shaped response from/api/oauth/usagewith onlyfive_hour,seven_day, andmodel_scoped. It never passesspendorextra_usage, soclaudeUsageResponseToLimitscannot emit themonthly_spendwindow that fix(claude): map monthly account spending limits #19433 added for the native probe.packages/shared/src/usageLimits.tscollectLimitAccountsmerges the native provider report and the hub account under the same account key, then takeswinner.limitswhole from whichever has the newercheckedAt.- Refreshing limits re-reads the hub (
UsageLimitSources.readSource), so the hub snapshot becomes the freshest. Its window list has nomonthly_spend, and the row disappears. It should come back the next time the native provider probe is newer than the hub read, so the row flickers depending on which reader ran last.
Either fix closes it: map the spend budget in the CLIProxy Claude read, or merge windows per window id across sources instead of taking one source's list whole.
Repro steps
- Sign in to Claude on a subscription with a monthly spending limit enabled, so the native probe reports "Monthly spend".
- In Settings, add a CLIProxy usage limit source that serves the same Claude account, and enable it.
- Open Usage, then Limits. The Claude card shows "Monthly spend".
- Click refresh. "Monthly spend" disappears while the other Claude rows remain.
Environment
- Version: 0.1.1-nightly.20261020.3438 (desktop app, macOS nightly channel), connecting to its local server. Triage CLI was 0.1.1.
- OS: macOS 26 (Darwin 25.6.0), arm64
- Usage limit sources: one CLIProxy source on localhost
- Claude provider instances: two (both lost the row after refresh)
Evidence
- Server caches and trace confirm the row is dropped client-side.
- Server trace:
UsageLimitSources.readSourceran at the refresh time and succeeded with no error. - Both Claude provider status caches still held
{"id":"monthly_spend","kind":"monthly","label":"Monthly spend"}withusedPercent26.43 and 1.02 after the refresh, matching the 74% and 99% bars shown before it. mainhas no changes tocliproxyApi.tsor the merge logic since the tag.
Related issues
- fix(claude): map monthly account spending limits #19433 added the monthly spend mapping for the native Claude probe only.
- [Bug]: Claude Enterprise spending budget is ignored, showing “No limits reported” #10155 (closed) covers the original request to show the Claude spending budget.
Filed via t3 triage by Claude Code (Claude Opus 5.5).
Reacted by fullheart
Metadata
Metadata
Assignees
Labels
No labels
Activity