Skip to content

fix(executor): validate download and cache completeness before reuse#251

Open
damilolaedwards wants to merge 1 commit into
ethpandaops:masterfrom
damilolaedwards:fix/cache-completeness-validation
Open

fix(executor): validate download and cache completeness before reuse#251
damilolaedwards wants to merge 1 commit into
ethpandaops:masterfrom
damilolaedwards:fix/cache-completeness-validation

Conversation

@damilolaedwards

Copy link
Copy Markdown

Cached artifacts were trusted on presence alone, so an incomplete write
could be served as valid indefinitely.

Range downloads ignored io.Copy's byte count, so a 206 body that ended
early left a zero-filled hole in the pre-allocated file with no error.
downloadChunk now verifies it received the full requested range, and the
single-GET path checks the body against the advertised size.

EEST preparation decided the cache was warm from the fixtures directory
existing, but fixtures and genesis extract in two steps. A run interrupted
between them was reused forever with genesis missing. Reuse is now gated on
a completion marker written only after both steps succeed, and a partial
cache is cleared and re-downloaded on the next run.

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