Commit 080d5f62 authored by Mark Tyneway's avatar Mark Tyneway Committed by GitHub

op-chain-ops: allocs validation (#10388)

Skip check for codesize on gov token address if governance is
not enabled.
parent 0c7d8a94
......@@ -62,6 +62,9 @@ func BuildL2Genesis(config *DeployConfig, dump *ForgeAllocs, l1StartBlock *types
// sanity check that all predeploys are present
for i := 0; i < 2048; i++ {
addr := common.BigToAddress(new(big.Int).Or(l2PredeployNamespace.Big(), big.NewInt(int64(i))))
if !config.GovernanceEnabled() && addr == predeploys.GovernanceTokenAddr {
continue
}
if len(genspec.Alloc[addr].Code) == 0 {
return nil, fmt.Errorf("predeploy %x is missing from L2 genesis allocs", addr)
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment