Repository navigation
Conversation
OAuth account lists become a card grid (or compact rows) with a toolbar for search, quota filters, sorting, title mode and view mode, pool availability and token estimates, and per-family Gemini/Claude limits for Antigravity. Each card keeps pause/resume, switch, alias, reauth, Grok coupons, Claude reset grants, the Kiro skip reason and the Anthropic per-account threshold. Removal asks in a dialog bound to the provider and server it was opened for. Antigravity gets a Cockpit Tools import card and an auth-choice modal, and the provider rail can collapse. A per-account refresh forces only that account upstream (accountId on GET /api/oauth/accounts; an unknown id forces all). The pools hook keeps the latest quota outcome with its generation, so a superseded refresh succeeds only when a newer outcome succeeded. The list rereads cached quota every 30s while visible; it does not force upstream probes, and the mount-time forced refresh is gone. Quota rosters keep four workers. Carried from #5408 (source head 2db9838). Co-authored-by: agentHits <140916359+agentHits@users.noreply.github.com>
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. 🗂️ Base branches to auto review: 2
Please check the settings in the CodeRabbit UI or the ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
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 |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4b7d9b00f4
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| <button | ||
| type="button" | ||
| className="pwi-dense-select-btn" | ||
| disabled={disabled || active || paused} | ||
| onClick={() => onSwitch(account)} |
There was a problem hiding this comment.
Block selection of unhealthy accounts
When an inactive account has needsReauth/reauth_required or a cooldown health status, this button remains enabled because it checks only disabled, active, and paused. The previous account list explicitly blocked both reauthentication and cooldown states, while the management route rejects only paused accounts, so clicking the redesigned card can make a credential known to be unusable the active account. Restore the health-state checks before invoking onSwitch.
AGENTS.md reference: gui/AGENTS.md:L9-L10
Useful? React with 👍 / 👎.
| {(analyzed.generic5h || analyzed.genericWeekly) ? ( | ||
| <> | ||
| {renderSingleQuotaBar(t("pws.window5hLabel"), analyzed.generic5h?.percent, analyzed.generic5h?.resetAt)} | ||
| {renderSingleQuotaBar(t("pws.windowWeeklyLabel"), analyzed.genericWeekly?.percent, analyzed.genericWeekly?.resetAt)} | ||
| </> | ||
| ) : ( | ||
| <ProviderAccountQuota quotaMode={account.quotaMode} quota={account.quota} | ||
| quotaUnavailable={account.quotaUnavailable} quotaPending={account.quotaPending} quotaFailure={account.quotaFailure} /> |
There was a problem hiding this comment.
Keep custom quota windows visible beside standard windows
When a non-Antigravity account has a standard 5-hour or weekly reading, this branch bypasses ProviderAccountQuota and renders only those two fields. Anthropic normally returns those fields together with model-family windows such as Opus, Sonnet, and Fable, so the redesigned cards hide the family limits that the old renderer displayed; the compact branch has the same conditional. Render the custom windows as well or continue using the complete quota renderer.
AGENTS.md reference: gui/AGENTS.md:L9-L10
Useful? React with 👍 / 👎.
| const allPercents: number[] = []; | ||
| if (gemVals.length > 0) allPercents.push(...gemVals); | ||
| if (claVals.length > 0) allPercents.push(...claVals); | ||
| if (generic5h) allPercents.push(generic5h.percent); | ||
| if (genericWeekly) allPercents.push(genericWeekly.percent); | ||
| for (const w of customWindows) { | ||
| if (typeof w.percent === "number") allPercents.push(w.percent); | ||
| } |
There was a problem hiding this comment.
Include monthly quota in readiness calculations
For providers whose account quota is monthly-only, notably paid Kiro accounts without a free-trial custom window, allPercents stays empty because monthlyPercent is never added. The card can still render the monthly bar through ProviderAccountQuota, but the toolbar labels the same account as quota-unknown, reports it unavailable, sorts it with zero headroom, and removes it under the “with limits” filter. Include the monthly reading and reset data in the analysis.
AGENTS.md reference: gui/AGENTS.md:L9-L10
Useful? React with 👍 / 👎.
| for (const w of customWindows) { | ||
| if (typeof w.percent === "number") allPercents.push(w.percent); | ||
| } |
There was a problem hiding this comment.
Do not treat one model-scoped limit as account exhaustion
When an Anthropic account has usable provider-wide limits but one scope: "model" custom window is exhausted (for example Opus at 100% while weekly usage is 20%), adding every custom percentage to this maximum makes fullyExhausted true and hasAnyLimitsLeft false. The toolbar then reports the whole account exhausted and the availability filter hides it even though other model families remain usable. Preserve the quota-window scope in the client type and exclude model-scoped windows from account-wide readiness.
AGENTS.md reference: gui/AGENTS.md:L9-L10
Useful? React with 👍 / 👎.
|
✅ Deterministic PR hygiene checks passed. |
⏳ DRAFT
What to do
Its title has been prefixed with |
Summary
Third slice carried from #5408 by @agentHits (source head
2db983800a02785250cc3ebed86f399bc772303e), stacked on #7168, which is stacked on #7167. Both refreshed parent heads are merged into this branch without force-pushing.OAuth account lists become cards or compact rows with search, quota filters, sorting, title/view switches, removal confirmation scoped to provider and server, and Antigravity's browser-login/Cockpit Tools import chooser. Existing pause, switch, alias, reauthentication, coupon/reset-grant and Anthropic threshold controls remain. Generic pool controls use #7168's single card and preserve Kiro's CLI strategy.
Independent review implemented all four owner UI decisions:
The 30-second roster poll stays cached, mount-time forced refresh stays removed, and quota rosters retain four workers. The API's targeted
accountIdsupport remains independently usable; it does not add a force button. Removal is bound to provider plus API base. Changed management routes retain the shared management-auth and origin gates.Screenshots
Real GUI builds served by sandboxed proxies, three synthetic Antigravity accounts without quota readings. Google Chrome/Playwright startup timed out on this machine (even
Google Chrome --versionhung at process startup); these replacement captures use GOAT's shared Chromium browser. No screenshot files are committed to a PR branch.origin/dev7640a94)Co-authored-by: agentHits 140916359+agentHits@users.noreply.github.com
Verification
Fresh runs on macOS arm64 / Bun 1.4.3, all tests/proxies with temporary
OPENCODEX_HOMEandCODEX_HOME, proxies on non-default ports:cd gui && bun run test: 3355 pass / 0 fail, 343 files. This includes all parent-layer fixes. After the final compact-badge-only cleanup,bun ../scripts/test-with-pinned-bun.ts --isolate tests/provider-quota-refresh-controls.test.tsx: 15 pass / 0 fail;bun run build: pass.bun scripts/test.ts --parallel=1 tests/gui/gui-account-quota-analysis.test.ts: 12 pass / 0 fail;bun scripts/test.ts --parallel=1 tests/server/server-management-auth.test.ts: 47 pass / 0 fail.bun run typecheck,cd gui && bun run lint,cd gui && bun run lint:i18n,bun run build:gui,bun run structure:check,bun run privacy:scan,bun scripts/file-size-ratchet.ts: pass.cd docs-site && bun install --frozen-lockfile && bun run build: pass (577 pages)./api/oauth/accounts?provider=google-antigravity,/api/provider-quotas, and/api/oauth/accounts?provider=google-antigravity"a=1, withoutrefresh=1. Synthetic accounts have no project id, so the screenshot's unavailable-quota result is expected.OPENCODEX_HOME=$(mktemp -d) CODEX_HOME=$(mktemp -d) OCX_TEST_NO_QUEUE=1 bun run test:changedinitial run completed: 40505 pass / 107 skip / 22 fail / 4 errors across 1866 files. Final-stack rerun completed in 372.4 seconds: 40507 pass / 107 skip / 21 fail / 4 errors, 1866 files. Its failures are the four baseline audio/sibling cases plus 17 service/ownership/toggle cases that pass in scoped runs on both trees. This is not a green root-suite claim.origin/dev7640a94, same nine initially failing files viabun scripts/test.ts --parallel=1: 518 pass / 4 fail / 4 errors. It reproduces three audio-readiness timeouts, sibling-home ensure timeout, and audio JSON/transport errors. Service/ownership/toggle failures do not reproduce in scoped runs. A tip rerun of the six service/toggle/headless files gave 398 pass / 2 fail, both 5-second headless CLI timeouts;bun scripts/test.ts --parallel=1 --timeout=30000 tests/cli/cli-headless-parity.test.tsthen passed 100/0 on both tip and clean dev. Broad-run-only ordering effects remain for CI to assess.Checklist