gemini-cli fixes lost usage tracking when stream aborts
PranavMishra28 · ghdev · 2026-08-07
A PR merged into Google's gemini-cli fixes the issue where token usage already received was not recorded when a stream was aborted. Previously, usage was only flushed on the success path, and the abort path lost it entirely because logApiError early-returns for AbortError. The fix flushes captured usage via logApiResponse before rethrowing, without reclassifying cancellation as an error. If no usage metadata was received before abort, no event is emitted, avoiding fabricated zero-usage records. Tests cover both cases.
More from coding & agent
- Comparing AI Subscriptions: DeepSeek API vs. Claude Pro vs. Local LLMs — Unlikely_Bluejay5392 · 2026-08-24
- Claude Code introduces 'Remote Control' feature to boost coding efficiency — rohanpaul_ai · 2026-08-24
- rauchg lays out fx extension philosophy: MCP, Skills, Plugins and Unix composition — AccBalanced · 2026-08-24
- Netflix details its production LLM judge: hundreds of thousands of recommendations scored weekly — omarsar0 · 2026-08-24
- smolvm passes Simon Willison's Fable 5 agent test as a secure sandbox — yawnxyz · 2026-08-24
- Claude EA Project: Virtual Assistant Integrated with Notion and iMessage — willcb · 2026-08-24