• Mark Tyneway's avatar
    op-chain-ops: export bedrock transition block extradata · 1f258d90
    Mark Tyneway authored
    Makes the extradata for the bedrock transition block
    a public variable. This is useful for exporting the
    value to be imported in other packages where assertions
    can be made to ensure that the extradata is correct.
    
    When fetching the `L2OutputOracle`'s configured starting
    block number, the L2 block with that number can be
    fetched and then we can assert that it has the magic
    extradata.
    
    ```bash
    $ cast call 0x02Ac1923480E7fd234e7F2Fd11596b9F20372374 'startingBlockNumber()(uint256)'
    3855343
    ```
    
    ```bash
    $ cast block 3855343 --json | jq -r .extraData
    0x424544524f434b
    ```
    
    Now check like so:
    
    ```bash
    $ cast --to-ascii 0x424544524f434b
    BEDROCK
    ```
    1f258d90
Name
Last commit
Last update
..
cmd Loading commit data...
crossdomain Loading commit data...
deployer Loading commit data...
ether Loading commit data...
genesis Loading commit data...
immutables Loading commit data...
state Loading commit data...
.gitignore Loading commit data...
Dockerfile Loading commit data...
Makefile Loading commit data...
README.md Loading commit data...
docker.go.work Loading commit data...
go.mod Loading commit data...
go.sum Loading commit data...