TestAntigravityManagerExecuteAndStream_ToppedUpCreditsRecoverDuringQuotaCooldown fails intermittently

Open
#8,162 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
Half a day
Newbie friendliness
42/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
go, testing-qa
Domain
testing

Research direction

The failing test is TestAntigravityManagerExecuteAndStream_ToppedUpCreditsRecoverDuringQuotaCooldown in internal/runtime/executor/antigravity_executor_credits_test.go, failing around line 985 when the credits hint is checked after recovery. Start by reading that test and the credits-hint update path it exercises, then reproduce with go test -count=30 -run on that test name. Done means the test passes reliably across repeated runs, most likely by fixing a timing or ordering race rather than loosening the assertion.

Written by the indexing model from the issue text.

Description

Written by an AI agent on behalf of @subsy.

Is it a request payload issue?
[ ] Yes, this is a request payload issue.
[x] No, it's another issue.

Describe the bug
TestAntigravityManagerExecuteAndStream_ToppedUpCreditsRecoverDuringQuotaCooldown in internal/runtime/executor/antigravity_executor_credits_test.go fails intermittently. It has hit both subtests:

--- FAIL: TestAntigravityManagerExecuteAndStream_ToppedUpCreditsRecoverDuringQuotaCooldown/execute
    antigravity_executor_credits_test.go:985: hint after recovery = auth.AntigravityCreditsHint{Known:false, Available:false, CreditAmount:0, MinCreditAmount:0, PaidTierID:"", UpdatedAt:...} (ok=true), want Known=true Available=true CreditAmount=2516
--- FAIL: TestAntigravityManagerExecuteAndStream_ToppedUpCreditsRecoverDuringQuotaCooldown/execute_stream
    antigravity_executor_credits_test.go:985: (same message)

How often:

  • main at 38fe9295: 2 of 30 runs failed with go test -count=30 -run '^TestAntigravityManagerExecuteAndStream_ToppedUpCreditsRecoverDuringQuotaCooldown$' ./internal/runtime/executor/ (Linux, go1.27.4).
  • Our fork, which has upstream up to 3a353935: 1 of 30 runs failed with the same command.
  • On GitHub's ubuntu-latest runners it failed in a full go test ./... on two days in a row (24 and 25 Nov).

Expected behavior
The test passes on every run.

OS Type

  • OS: Linux, go1.27.4

Additional context
Not tied to a CLI type, model or client: it's an intermittent unit test failure.

Dominant language
Go
Stars
59.4k
Forks
9.1k
Avg merge
11h 50m
Merged PRs (30d)
67

Getting set up

  • Ships a Dockerfile or Docker Compose file
  • No pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from router-for-me/CLIProxyAPI

All issues in router-for-me/CLIProxyAPI

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.