Files
orca/src
Shani SinghandNeil 38c0c22b2e fix(usage): rebuild corrupt per-source usage cache records instead of failing every scan (#42418)
A null or non-object entry in a per-source usage sidecar made the Codex,
Muse and OpenCode scans throw, and since a failed scan never rewrites the
sidecar the failure repeated on every refresh. Records missing their
sessions/dailyAggregates projections were either reused as zero usage
(Muse/OpenCode) or crashed the Codex reuse and incremental-resume paths.

- readUsageSourceCache drops entries that are not plain objects.
- Muse and OpenCode normalizers drop records lacking projection arrays so
  the source is reparsed.
- Codex requires both projection arrays before reusing or resuming a
  cached rollout record.

Fixes #42413

Co-authored-by: Neil <neil@stably.ai>
2026-11-14 14:23:59 -08:00
..