MinaProtocol / mina

Mina is a cryptocurrency protocol with a constant size blockchain, improving scaling while maintaining decentralization and security.
https://minaprotocol.com
Apache License 2.0
1.98k stars 526 forks source link

Ledger hash verification of incremental AN migration on mainnet #15586

Open deepthiskumar opened 2 months ago

deepthiskumar commented 2 months ago

Automate to test twice a week or so

ghost-not-in-the-shell commented 2 months ago

I verified that my migration and dariusz migration all passes the berkeley-migration-verifier final checks. Currently working on a cronjob that verifies our mainnet incremental migration dumps on daily basis. Here's the basic steps:

  1. We need a cronjob on mainnet to dump the fork config on seed-5 daily and then we need to generate the new genesis config using either the hard fork pipeline or just using the generate-genesis-config.sh to print it out using a mina-daemon docker image
  2. Once we have the new genesis config, we could take the most recent mainnet dump and some increment migration dump and do the final migration on it. We need to make sure that the mainnet dump we choose have the fork block in it and we need to mark the blocks after the fork block to be "pending", another thing is that the incremental migration dump should not include the fork block.

So for the input, the cron job would take a fork-genesis-config.json, a mainnet archive dump and an incremental migration dump, and it would just run the berkeley-migration-script final on those 3 input and report the result somewhere.