fix: preserve unknown Antigravity families
Co-authored-by: Urda <github@urda.com>
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
## 0.49.6 — Unreleased
|
||||
|
||||
### Fixed
|
||||
- Antigravity: hide untouched model families from compact menu cards and widgets while keeping unknown-usage families visible and preserving every family in provider details and all-untouched states (#2875). Thanks @urda!
|
||||
- Ollama: allow the `auto` and `web` usage sources on Linux when a non-empty manual Cookie header is configured, while keeping automatic browser-cookie imports gated to supported platforms (#2919). Thanks @dhabyx!
|
||||
- Codex: preserve the wider retained cost history when Usage & Spend saves a 7- or 30-day projection under cache row/byte pressure, instead of pruning older rows and narrowing the persisted scan window (#2914, #2915). Thanks @thomaschow19!
|
||||
- Claude: reuse the last successful CLI usage result for 15 minutes during background refreshes instead of relaunching the ~280 MB Claude Code binary on every tick, cutting background disk reads and process churn for CLI-sourced usage; manual refreshes still probe immediately (#2916).
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import Foundation
|
||||
|
||||
/// Antigravity reports every model family the plan covers, so an account that only runs Gemini still
|
||||
/// receives a Claude/GPT pair pinned at 0%. Display surfaces hide a family once no lane in it reports
|
||||
/// known usage above zero. Menu bar and icon selection rank by highest used, so an untouched family
|
||||
/// receives a Claude/GPT pair pinned at 0%. Display surfaces hide a family once every lane in it reports
|
||||
/// known zero usage. Menu bar and icon selection rank by highest used, so an untouched family
|
||||
/// never wins there and this stays a display-only filter.
|
||||
public enum AntigravityQuotaFamilyVisibility {
|
||||
/// Window IDs that display surfaces should drop. Empty when every family is untouched, so a card
|
||||
@@ -13,7 +13,7 @@ public enum AntigravityQuotaFamilyVisibility {
|
||||
guard !windows.isEmpty else { return [] }
|
||||
let families = Dictionary(grouping: windows, by: Self.familyKey)
|
||||
let idleFamilies = families.filter { _, lanes in
|
||||
lanes.allSatisfy { !$0.usageKnown || $0.window.usedPercent <= 0 }
|
||||
lanes.allSatisfy { $0.usageKnown && $0.window.usedPercent <= 0 }
|
||||
}
|
||||
guard idleFamilies.count < families.count else { return [] }
|
||||
return Set(idleFamilies.values.flatMap { lanes in lanes.map(\.id) })
|
||||
|
||||
@@ -541,7 +541,7 @@ struct MenuCardAntigravityTests {
|
||||
}
|
||||
|
||||
@Test
|
||||
func `antigravity quota summary hides a family whose only known lane is untouched`() throws {
|
||||
func `antigravity quota summary keeps a family with unknown usage`() throws {
|
||||
let now = Date(timeIntervalSince1970: 1_735_000_000)
|
||||
let model = try Self.quotaSummaryModel(
|
||||
windows: [
|
||||
@@ -560,6 +560,8 @@ struct MenuCardAntigravityTests {
|
||||
#expect(model.metrics.map(\.id) == [
|
||||
"antigravity-quota-summary-gemini-5h",
|
||||
"antigravity-quota-summary-gemini-weekly",
|
||||
"antigravity-quota-summary-3p-5h",
|
||||
"antigravity-quota-summary-3p-weekly",
|
||||
])
|
||||
}
|
||||
|
||||
|
||||
+5
-5
@@ -233,11 +233,11 @@ shared OAuth file can still be used as a fallback credential source.
|
||||
in `extraRateWindows` for reset context and are marked with `usageKnown: false`; clients should not render their
|
||||
`usedPercent` as a real exhausted quota.
|
||||
- Antigravity reports every model family the plan covers, so an account that only uses Gemini still receives a
|
||||
Claude/GPT pair pinned at 0%. Menu cards and widgets hide a family once no lane in it reports known usage above
|
||||
zero, and keep every family when they are all untouched, for example right after a weekly reset. Provider details
|
||||
is the diagnostic surface and always lists every family, the same principle it already applies to cost data. The
|
||||
filter is display-only: the snapshot, CLI output, and menu-bar ranking still see every window, and menu-bar
|
||||
selection ranks by highest used, so an untouched family never wins there anyway.
|
||||
Claude/GPT pair pinned at 0%. Menu cards and widgets hide a family once every lane in it reports known zero usage.
|
||||
A family with unknown usage stays visible, and every family remains visible when all are untouched, for example
|
||||
right after a weekly reset. Provider details is the diagnostic surface and always lists every family, the same
|
||||
principle it already applies to cost data. The filter is display-only: the snapshot, CLI output, and menu-bar
|
||||
ranking still see every window, and menu-bar selection ranks by highest used, so an untouched family never wins.
|
||||
|
||||
## Constraints
|
||||
- Internal protocol; fields may change.
|
||||
|
||||
Reference in New Issue
Block a user