Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

validate cached blockchains #18527

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft

validate cached blockchains #18527

wants to merge 2 commits into from

Conversation

arvidn
Copy link
Contributor

@arvidn arvidn commented Aug 26, 2024

Purpose:

Prevent BlockTools to drift away from the chains stored in test-cache (i.e. ensure changes to BlockTools are caught by CI so we can update the cache)

When loading the cached test blockchains, check that the first few blocks match what we would have generated if it wasn't cached. This should make CI highlight whenever BlockTools changes some way of how chains are generated that alters the chain output. When this happens, we should also update the test-cache repo.

The test chains in test-cache have diverged from what's generated by BlockTools today. Probably at least in #18209

Current Behavior:

If we find cached blockchains, we use them and assume they are right.

New Behavior:

If we find cached blockchains, we check the first 5 blocks to ensure they match what we would have generated, then use them.

@arvidn arvidn added Added Required label for PR that categorizes merge commit message as "Added" for changelog Tests Changes to tests labels Aug 26, 2024
@AmineKhaldi
Copy link
Contributor

My candidates for logic changes potentially leading to that are #16881 and #18209.

arvidn added 2 commits August 26, 2024 18:53
…ocks match what we would have generated if it wasn't cached. This should make CI highlight whenever BlockTools changes some way of how chains are generated that alters the chain output. When this happens, we should also update the test-cache repo
@arvidn arvidn force-pushed the validate-test-cache branch from 96323d1 to 1acf025 Compare August 26, 2024 17:16
Copy link
Contributor

This PR has been flagged as stale due to no activity for over 60 days. It will not be automatically closed, but it has been given a stale-pr label and should be manually reviewed by the relevant parties.

@github-actions github-actions bot added the stale-pr Flagged as stale and in need of manual review label Oct 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Added Required label for PR that categorizes merge commit message as "Added" for changelog stale-pr Flagged as stale and in need of manual review Tests Changes to tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants