Session usage: remaining follow-ups from #7862
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 28/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- typescript
- Ambito
- full-stack
Direzione di ricerca
Three separate deferred items. Start from getSessionUsage and the ledger repair path, where recordUsage (its messageId option) and settledInFlightKeys decide whether a settle double-counts. Item 2 is WorkspaceStore.refreshUsageAfterChange, which logs a failed refetch and stops. Item 3 is refreshSessionUsage, which is latest-wins rather than single flight. Each item needs its own test and its own definition of done; item 1 needs a new persisted ledger field.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Open items left from #7862 after #7865, #7866, #7867 and #7868 merged. Each one is rare, and none was seen in the 6,714 real ledgers checked for #7868.
- A settle counts a message twice after a locked repair, for a stream without an in-flight key. The stream has no key only when every one of its in-flight writes failed. Then
getSessionUsage(or a token-stats cache update) can rebuild an unusable ledger from history, which already holds the final message, and the later settle adds that message again. #7868 covers this window whenrecordUsagedoes the repair itself (itsmessageIdoption) and when the stream has an in-flight key (settledInFlightKeys). A fix must persist which messages the repair counted, so it needs a new ledger field. (Item 9 of #7862, deferred from #7868 review round 5.) - A failed
usage-changedrefetch is not retried. When a transientgetSessionUsageor ancestorgetSubagentUsageerror fails the refetch,WorkspaceStore.refreshUsageAfterChangelogs it and stops. The Costs tab stays stale until the next usage change, an activation, a Costs tab open or an activity resubscribe. Fix: retry with bounded backoff, or keep a per-workspace "refresh pending" flag until a fetch succeeds. (Deferred from #7867.) refreshSessionUsageis latest-wins, not single flight. A burst of usage writes on one shown workspace whose chat is not subscribed (for example headless records) costs onegetSessionUsageeach. Act on it when a profile showsgetSessionUsagebursts. (Deferred from #7867. #7870 tracks the projection side.)
Related: #7870 (projection refetch throttle), #7883 (removal loses a sub-agent's spend when the roll-up fails), #7884 (rebuild drops an in-flight settled marker when the scan fails).
Generated with xum • Model: anthropic:claude-opus-5-5 • Thinking: high
- Lingua principale
- TypeScript
- Stelle
- 2.1k
- Fork
- 139
- Merge medio
- 5h 5m
- PR unite (30g)
- 923
Preparare l'ambiente
- Include un Dockerfile o un file Docker Compose
- Nessun modello di pull request
- Nessuna guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di coder/xum
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
I maintainer di solito rispondono entro 1 giorno
-
🤖 fix: xum api exits 0 when a procedure returns success: falseForse già presa @twotnguyen l’ha presa 4 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
I maintainer di solito rispondono entro 1 giorno
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
home-assistant/frontend#55841 ·
I maintainer di solito rispondono entro 1 giorno
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 76/100
lingdojo/kana-dojo#33905 · 1 commento · 5 reazioni ·
I maintainer di solito rispondono entro 1 giorno
-
bug(semester-planning): the edit application dialog cannot save with an empty «Annet fra bedriften»Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
blocklist removal
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
MetaMask/eth-phishing-detect#311215 ·
I maintainer di solito rispondono entro 1 giorno
-
Explore filter: multi-select value list with allowNewOptions stops accepting values and drops earlier onesForse già presa @isaac-jaynes-imperva l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
apache/superset#46146 · 1 commento ·
I maintainer di solito rispondono entro 2 giorni