Repository navigation
Conversation
/api/oauth/usage reports model caps only in its limits list (weekly_scoped with scope.model.display_name); the seven_day_opus and seven_day_sonnet keys come back null. Read those rows as extra windows labelled by model, and raise the per-row meter cap from 2 to 3 so the footer popover and Settings show them.
5 of 6 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
/api/oauth/usagereports model caps only in itslimitslist (kind: "weekly_scoped",scope.model.display_name). The legacyseven_day_opus/seven_day_sonnetkeys come backnull. Zeron only readfive_hourandseven_day, so an account at 85% of its Fable cap showed "Week 70%" and looked like it had room.MAX_USAGE_METERS = 3. Side effect: Copilot Free can now show its third quota (Completions) as well.Test plan
claude_usage_windows_add_per_model_weekly_limits, built from the response shape seen live (null legacy keys,limitswith session / weekly_all / weekly_scoped).cargo test -p zeron-engine --lib claude_usage_windows: 3 passed.weekly_scopedFable at 85% (severity: warning) whileseven_daywas 70%.ZERON_DATA_DIR=~/.zeron-dev) Settings → Providers → Claude Code → Accounts shows Session 23% / Week 70% / Fable 85% (warning color) for the live account.render_usage_meterand the same cap.cargo clippy -p zeron-engine -p zeron-ui --all-targets: no new warnings.Screenshots
Before (footer popover, v0.2.103): Week 70%, no Fable row
(image to attach)
After (Settings → Accounts, dev build): Fable 85% shown in warning color
(image to attach)
Need help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.