fix(codex): label weekly-only rate limits correctly#8493
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (7)
📝 WalkthroughWalkthroughCodex rate-limit window classification now detects weekly durations and maps primary and secondary windows into session and weekly fields across backend and RPC fetch paths. New tests cover weekly-only, session-only, and dual-window responses. Status-bar usage labels derive weekly durations dynamically, and mini meters use the first available visible window. Renderer tests cover weekly-only Codex usage displays. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Also facing this issue since latest update |
|
Thanks for the Codex weekly-window classification work. This PR targets a different problem (sole 7-day primary windows mislabeled as session/5h) rather than #8378’s chip-vs-popup remaining-time mismatch. Merged #9004, which syncs the status-bar chip to remaining reset duration when Closing here for #8378. If the weekly-only labeling issue is still open on main, please re-target a fresh PR against that bug (related: #8293) — happy to review that separately. |
|
Reopening: this PR addresses weekly-only Codex quota labeling (sole 7-day window mis-shown as 5h session), not the #8378 chip-vs-popup remaining-time fix that landed in #9004. Sorry for the mistaken close during the #8378 duplicate sweep. Please continue review on the weekly-labeling work as a separate change. |
Resolve StatusBar mini-meter conflict by keeping the first-visible-window source from this branch and adopting the display prop from main. Keep the weekly-only tests and take main's renamed remaining-fill test title.
|
Thanks for catching this and reopening, @nwparker ! I've rebased against main and resolved the merge conflicts in StatusBar.tsx and inline-usage-bars.test.tsx. Ready for review whenever convenient. |
Summary
User-visible change
Codex plans that expose only a weekly quota no longer show that quota as a five-hour session limit. The compact usage bar remains visible and follows the weekly percentage when no five-hour window exists.
Screenshots
Testing
pnpm lint(passes with repository-existing warnings)pnpm typecheckpnpm buildpnpm check:max-lines-ratchetgit diff --check origin/main...HEADpnpm test: the workstation suite has unrelated Git environment/hook and UTF-8 fixture failures; all changed-area tests passAI Review Report
Compatibility notes
A sole 5h primary window remains
session. When 5h and weekly windows both exist, 5h remains first and drives the compact mini meter. A sole weekly primary window is reclassified asweeklyand drives that same meter.Related to #8378 and #8293.
No release/version changes.
X: @KyungyeolB