Skip to content

fix(worker): cap LHM cache recovery with a prior receipt hash - #130

Merged
austinjiann merged 1 commit into
mainfrom
codex/cache-recovery-receipt
Nov 21, 2026
Merged

austinjiann merged 1 commit into
mainfrom
codex/cache-recovery-receipt

Conversation

@austinjiann

@austinjiann austinjiann commented Nov 20, 2026 •

Copy link
Copy Markdown
Collaborator

A deadline during the first LHM range recovery leaves useful partial files but no supported final recovery path. Add an explicit, hash-bound final slot that accepts only the exact failed deadline receipt and eligible incomplete cache. Preserve both earlier receipts, record prior/current call IDs and attempt 3 overall / range attempt 2, and refuse every replay of the fixed final slot. Ordinary recovery behavior remains unchanged.

The operator must verify the prior app is terminal and persist an exclusive local launch claim; the Modal volume alone is not a cross-launcher atomic lock. No automatic retry or arbitrary attempt naming is introduced.

Validation: 90 offline tests on Python 3.11 and 54 focused tests on Python 3.12; CLI parsing, Ruff, format checks and diff checks passed. Tests cover receipt/hash/state rejection, retained history, ownership persisted before ranges, Git-payload exclusion and final-slot replay refusal. Live validation completed in austinjian07: the final slot reused 65 entries, extracted 33 runtime entries and fetched 2,175,449,183 range bytes. It validated 70 runtime files plus the pinned LHM snapshot and detector checkpoint. Both earlier receipt files remained byte-identical, and the owned app stopped. This establishes cache staging, not GPU inference or scene quality. Stacked on #129.

@austinjiann
austinjiann changed the base branch from codex/cache-archive-metadata to main November 21, 2026 04:17
@austinjiann
austinjiann merged commit dc9cc87 into main Nov 21, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant