Skip to content

Account Pooler: Provider usage keeps showing old readings after the plugin is disabled, and failed usage refreshes are silent #7739

Description

@scheinriese

bb 0.49.0 · plugin SDK 0.6.132 · macOS

What happens

  1. Account Pooler is on with a Claude account; Provider usage shows its windows.
  2. Disable the Account Pooler plugin (Settings → Plugins, or by accident).
  3. Open Provider usage: it still shows "Account Pooler" with the last readings, as if live. Reload and restarting bb change nothing.

Only bb plugin list shows account-pool … disabled. The only log line is Account Pooler disable inspection timed out. (from the onDispose hook), which doesn't say the plugin is off.

In our case the last reading said Claude extra usage was rejected. Credits were topped up afterwards, but nothing could update the reading, so other plugins (and the user) kept treating credits as blocked. Re-enabling the plugin fixed it within seconds.

Related: refresh failures leave no trace

Even while the plugin is enabled, a failed usage refresh is silent:

  • in the Claude adapter, refreshUsage ignores a non-OK response from /api/oauth/usage (await r.body?.cancel()) and returns
  • refreshAccountUsage ends with .catch(() => {})
  • a refresh is skipped while a request on that account is in flight

So a 401, a 429 or a response that fails the schema leaves account_quota stale with nothing in plugin.log.

Expected

  • Provider usage marks a disabled source (or hides it) instead of showing its last readings as current.
  • Each reading shows how old it is ("checked 14:02").
  • Failed refreshes are logged at warn level with the HTTP status.

Activity

  1. added theissue type on Nov 17, 2026
  2. added
    providers
    plugins
    partial-repro
    on Nov 17, 2026
  3. bb-slop-cop commented on Nov 17, 2026

    @bb-slop-cop
    Contributor

    🚨 SLOP COP 🚨 · new-issue-autopilot

    • Classification: Bug · Priority: Medium · Effort: Medium. Applied labels: providers, plugins, partial-repro.
    • Report: https://get-bb.github.io/reports/issues/7739.html
    • Verdict: PARTIALLY REPRODUCED · Confidence: high for silent refresh failures.
    • Root cause: Non-OK/invalid Claude usage responses leave quota unchanged, and the hub swallows refresh exceptions. Four regression cases (401, 429, invalid payload, network failure) reproduced unchanged successful readings and no warning logs in two clean trusted-main checkouts.
    • Limits: Disabled-source persistence did not reproduce in current-main lifecycle checks; the historical macOS/credit incident remains unverified. Existing Account Pooler tests (394), Provider Usage tests (23), and the focused core disable/discovery test pass.
    • No PR: A complete repair spans plugins and changes the freshness RPC schema/UI, outside the simple-fix limits.
  4. lanjak commented on Nov 19, 2026

    @lanjak
    Contributor

    Hi, I picked this up. On main at 7833dffd0f the silent part reproduces for both providers: an HTTP error, an unreadable usage response or a network error leaves the last reading as ok, and nothing is logged.

    #7852 covers that part:

    • A failed usage refresh is logged once per account and reason, with the HTTP status: Account Pooler claude account <id> usage refresh failed: the usage endpoint returned HTTP 429.
    • The account's usage turns into an error state until a refresh succeeds. Provider usage keeps the last reading on that row and shows "Usage could not be refreshed: ... Showing last update." So other readers can tell the reading is stale.
    • bb pool account refresh <id> fails with usage_refresh_failed instead of printing "Refreshed usage".
    • Routing is unaffected. The failure is not stored as the account's error, which would take the account out of rotation.

    Not in #7852:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    partial-repropluginsproviders

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions