Hive
Missing CAS object during replay fails the build instead of recompiling
GitHub issue · Open
What happened
During the production rebench of the snapshot-era cas-plugin (canary.20 against kura 0.15.2), a cold build resolved action-cache entries from a stale snapshot whose blobs had since been evicted by production CAS churn. Two demand loads hit those evicted objects; FETCH_OBJECT correctly reported not-found after exhausting every source (pending instructions, publish cache, snapshot node table, remote batch read) — and the build failed with exit 65:
error: CAS error: missing object '0~PrRJCIbHVmuMQ7X9VJNQyyyXAF2aNmUp4xYutmJtjISAGh9GD51YHwmJBDP7_mD1h8MxlKVwM9mdtwecQLEYdQ=='
Why this matters
The eviction window is not closable server-side: any presence gate vouches at a point in time, and a build takes minutes — the per-key path has the same exposure (manifest fetched at minute 0, blobs pulled at minute 8 after eviction). The design assumption was that a genuinely unavailable object degrades to a warning + recompile (Swift’s compilation-replay path does exactly that), with clang’s hard-fail mitigated by retained fetch instructions and the snapshot fallback. This failure shows a consumer — the error shape suggests swift-driver’s own CAS read rather than compilation replay — that treats the miss as fatal.
What needs doing
- Attribute the fatal consumer precisely (which task type issues this load, and through which llcas entry point).
- Decide the mitigation: ideally the plugin degrades a definitive FETCH_OBJECT miss into something the consumer can recover from (e.g. surfacing the miss at action-cache-get level so the key resolves as a miss and the task recomputes, rather than failing a load mid-task) — or, if the consumer is inherently strict, the served association must be invalidated before the consumer commits to replaying it.
- The staleness that widened the window in this incident is tracked separately (observability shipping in #11780); this issue stands regardless, because eviction can race even a fresh snapshot or a per-key hit.
Reproduced on: canary.20 client, kura 0.15.2, production tuist namespace, 2026-07-12.
🤖 Generated with Claude Code
Investigate, reproduce, or fix this item in an isolated repository. Each Flight preserves its outcome and agent session.
Start a Flight and preserve its objective, outcome, and session here.
No GitHub comments yet.