From 9ef832549b8c711750b822898cc26c9edafd6a84 Mon Sep 17 00:00:00 2001 From: Tess Rinearson Date: Tue, 27 Aug 2024 08:54:51 +0200 Subject: [PATCH 01/30] permit testnets and devnets to use newer contract versions (#508) * permit testnets and devnets to use newer contract versions * tidy * don't perform bytecode checking for testnets * avoid reimporting superchain package --- superchain/superchain.go | 6 +-- validation/go.mod | 2 +- validation/superchain-version_test.go | 67 +++++++++++++++++++++++---- 3 files changed, 62 insertions(+), 13 deletions(-) diff --git a/superchain/superchain.go b/superchain/superchain.go index d5a138476..c33d444fb 100644 --- a/superchain/superchain.go +++ b/superchain/superchain.go @@ -458,7 +458,7 @@ func (c ContractVersions) Check(allowEmptyVersions bool) error { } return fmt.Errorf("empty version for field %s", val.Type().Field(i).Name) } - str = canonicalizeSemver(str) + str = CanonicalizeSemver(str) if !semver.IsValid(str) { return fmt.Errorf("invalid semver %s for field %s", str, val.Type().Field(i).Name) } @@ -466,10 +466,10 @@ func (c ContractVersions) Check(allowEmptyVersions bool) error { return nil } -// canonicalizeSemver will ensure that the version string has a "v" prefix. +// CanonicalizeSemver will ensure that the version string has a "v" prefix. // This is because the semver library being used requires the "v" prefix, // even though -func canonicalizeSemver(version string) string { +func CanonicalizeSemver(version string) string { if !strings.HasPrefix(version, "v") { version = "v" + version } diff --git a/validation/go.mod b/validation/go.mod index 7adb574aa..a384ceae4 100644 --- a/validation/go.mod +++ b/validation/go.mod @@ -12,6 +12,7 @@ require ( github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240814192743-ea7e768a02a6 github.com/ethereum/go-ethereum v1.14.7 github.com/stretchr/testify v1.9.0 + golang.org/x/mod v0.20.0 ) require ( @@ -82,7 +83,6 @@ require ( github.com/yusufpapurcu/wmi v1.2.3 // indirect golang.org/x/crypto v0.26.0 // indirect golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56 // indirect - golang.org/x/mod v0.20.0 // indirect golang.org/x/net v0.27.0 // indirect golang.org/x/sync v0.8.0 // indirect golang.org/x/sys v0.23.0 // indirect diff --git a/validation/superchain-version_test.go b/validation/superchain-version_test.go index da25fde3d..5e15abb82 100644 --- a/validation/superchain-version_test.go +++ b/validation/superchain-version_test.go @@ -21,6 +21,8 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/ethclient" + + "golang.org/x/mod/semver" ) var contractsToCheckVersionAndBytecodeOf = []string{ @@ -50,15 +52,22 @@ func testContractsMatchATag(t *testing.T, chain *ChainConfig) { client, err := ethclient.Dial(rpcEndpoint) require.NoErrorf(t, err, "could not dial rpc endpoint %s", rpcEndpoint) + // testnets and devnets are permitted to use newer contract versions + // than the versions specified in the standard config + isTestnet := (chain.Superchain == "sepolia" || chain.Superchain == "sepolia-dev-0") + versions, err := getContractVersionsFromChain(*Addresses[chain.ChainID], client) require.NoError(t, err) - _, err = findOPContractTagInVersions(versions) + _, err = findOPContractTagInVersions(versions, isTestnet) require.NoError(t, err) - bytecodeHashes, err := getContractBytecodeHashesFromChain(chain.ChainID, *Addresses[chain.ChainID], client) - require.NoError(t, err) - _, err = findOPContractTagInByteCodeHashes(bytecodeHashes) - require.NoError(t, err) + // don't perform bytecode checking for testnets + if !isTestnet { + bytecodeHashes, err := getContractBytecodeHashesFromChain(chain.ChainID, *Addresses[chain.ChainID], client) + require.NoError(t, err) + _, err = findOPContractTagInByteCodeHashes(bytecodeHashes) + require.NoError(t, err) + } } // getContractVersionsFromChain pulls the appropriate contract versions from chain @@ -281,7 +290,7 @@ func TestFindOPContractTag(t *testing.T) { PreimageOracle: "1.0.0", } - got, err := findOPContractTagInVersions(shouldMatch) + got, err := findOPContractTagInVersions(shouldMatch, false) require.NoError(t, err) want := []standard.Tag{"op-contracts/v1.4.0"} require.Equal(t, got, want) @@ -296,13 +305,13 @@ func TestFindOPContractTag(t *testing.T) { ProtocolVersions: "1.0.0", L2OutputOracle: "1.0.0", } - got, err = findOPContractTagInVersions(shouldNotMatch) + got, err = findOPContractTagInVersions(shouldNotMatch, false) require.Error(t, err) want = []standard.Tag{} require.Equal(t, got, want) } -func findOPContractTagInVersions(versions ContractVersions) ([]standard.Tag, error) { +func findOPContractTagInVersions(versions ContractVersions, isTestnet bool) ([]standard.Tag, error) { matchingTags := make([]standard.Tag, 0) pretty, err := json.MarshalIndent(versions, "", " ") if err != nil { @@ -319,7 +328,7 @@ func findOPContractTagInVersions(versions ContractVersions) ([]standard.Tag, err matchesTag := func(standard, candidate ContractVersions) bool { s := reflect.ValueOf(standard) c := reflect.ValueOf(candidate) - return checkMatch(s, c) + return checkMatchOrTestnet(s, c, isTestnet) } for tag := range standard.Versions { @@ -387,3 +396,43 @@ func checkMatch(s, c reflect.Value) bool { } return true } + +// checkMatchOrTestnet returns true if s and c match, OR if the chain is a testnet and s < c +func checkMatchOrTestnet(s, c reflect.Value, isTestnet bool) bool { + // Iterate over each field of the standard struct + for i := 0; i < s.NumField(); i++ { + + if s.Type().Field(i).Name == "ProtocolVersions" { + // We can't check this contract: + // (until this issue resolves https://github.com/ethereum-optimism/client-pod/issues/699#issuecomment-2150970346) + continue + } + + field := s.Field(i) + + if field.Kind() != reflect.String { + panic("versions must be strings") + } + + if field.String() == "" { + // Ignore any empty strings, these are treated as "match anything" + continue + } + + if field.String() != c.Field(i).String() { + if !isTestnet { + return false + } + + // testnets are permitted to have contract versions that are newer than what's specified in the standard config + // testnets may NOT have contract versions that are older. + min := CanonicalizeSemver(field.String()) + current := CanonicalizeSemver(c.Field(i).String()) + if semver.Compare(min, current) > 0 { + return false + } + + } + } + return true +} From 8a84609f1a0191aa2d4c89fa94fd480ddd01c116 Mon Sep 17 00:00:00 2001 From: refcell Date: Tue, 27 Aug 2024 10:43:55 -0400 Subject: [PATCH 02/30] feat(bindings): Superchain Crate (#511) * feat(bindings): superchain crate * feat(bindings): superchain crate --- .github/CODEOWNERS | 1 + bindings/superchain/Cargo.lock | 864 +++++++++++++++++++++++++++++++++ bindings/superchain/Cargo.toml | 35 ++ bindings/superchain/Justfile | 61 +++ bindings/superchain/README.md | 69 +++ bindings/superchain/src/lib.rs | 18 + justfile | 4 + 7 files changed, 1052 insertions(+) create mode 100644 bindings/superchain/Cargo.lock create mode 100644 bindings/superchain/Cargo.toml create mode 100644 bindings/superchain/Justfile create mode 100644 bindings/superchain/README.md create mode 100644 bindings/superchain/src/lib.rs diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 05c8da896..72764885f 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -7,6 +7,7 @@ *.rs @ethereum-optimism/rust-reviewers Cargo.toml @ethereum-optimism/rust-reviewers /bindings/rust-* @ethereum-optimism/rust-reviewers +/bindings/superchain @ethereum-optimism/rust-reviewers .github/workflows/rust-checks.yml @ethereum-optimism/rust-reviewers .github/workflows/release.yml @ethereum-optimism/rust-reviewers diff --git a/bindings/superchain/Cargo.lock b/bindings/superchain/Cargo.lock new file mode 100644 index 000000000..a4ee9ec06 --- /dev/null +++ b/bindings/superchain/Cargo.lock @@ -0,0 +1,864 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "ahash" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" +dependencies = [ + "cfg-if", + "once_cell", + "version_check", + "zerocopy", +] + +[[package]] +name = "allocator-api2" +version = "0.2.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c6cb57a04249c6480766f7f7cef5467412af1490f8d1e243141daddada3264f" + +[[package]] +name = "alloy-consensus" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "04c309895995eaa4bfcc345f5515a39c7df9447798645cc8bf462b6c5bf1dc96" +dependencies = [ + "alloy-eips", + "alloy-primitives", + "alloy-rlp", + "alloy-serde", + "serde", +] + +[[package]] +name = "alloy-eips" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d9431c99a3b3fe606ede4b3d4043bdfbcb780c45b8d8d226c3804e2b75cfbe68" +dependencies = [ + "alloy-primitives", + "alloy-rlp", + "alloy-serde", + "c-kzg", + "serde", + "sha2", +] + +[[package]] +name = "alloy-genesis" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79614dfe86144328da11098edcc7bc1a3f25ad8d3134a9eb9e857e06f0d9840d" +dependencies = [ + "alloy-primitives", + "alloy-serde", + "serde", +] + +[[package]] +name = "alloy-primitives" +version = "0.7.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ccb3ead547f4532bc8af961649942f0b9c16ee9226e26caa3f38420651cc0bf4" +dependencies = [ + "alloy-rlp", + "bytes", + "cfg-if", + "const-hex", + "derive_more", + "hex-literal", + "itoa", + "ruint", + "serde", + "tiny-keccak", +] + +[[package]] +name = "alloy-rlp" +version = "0.3.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26154390b1d205a4a7ac7352aa2eb4f81f391399d4e2f546fb81a2f8bb383f62" +dependencies = [ + "alloy-rlp-derive", + "bytes", +] + +[[package]] +name = "alloy-rlp-derive" +version = "0.3.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d0f2d905ebd295e7effec65e5f6868d153936130ae718352771de3e7d03c75c" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.76", +] + +[[package]] +name = "alloy-serde" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e33feda6a53e6079895aed1d08dcb98a1377b000d80d16370fbbdb8155d547ef" +dependencies = [ + "alloy-primitives", + "serde", + "serde_json", +] + +[[package]] +name = "alloy-sol-macro" +version = "0.7.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b40397ddcdcc266f59f959770f601ce1280e699a91fc1862f29cef91707cd09" +dependencies = [ + "alloy-sol-macro-expander", + "alloy-sol-macro-input", + "proc-macro-error", + "proc-macro2", + "quote", + "syn 2.0.76", +] + +[[package]] +name = "alloy-sol-macro-expander" +version = "0.7.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "867a5469d61480fea08c7333ffeca52d5b621f5ca2e44f271b117ec1fc9a0525" +dependencies = [ + "alloy-sol-macro-input", + "const-hex", + "heck", + "indexmap", + "proc-macro-error", + "proc-macro2", + "quote", + "syn 2.0.76", + "syn-solidity", + "tiny-keccak", +] + +[[package]] +name = "alloy-sol-macro-input" +version = "0.7.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2e482dc33a32b6fadbc0f599adea520bd3aaa585c141a80b404d0a3e3fa72528" +dependencies = [ + "const-hex", + "dunce", + "heck", + "proc-macro2", + "quote", + "syn 2.0.76", + "syn-solidity", +] + +[[package]] +name = "alloy-sol-types" +version = "0.7.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a91ca40fa20793ae9c3841b83e74569d1cc9af29a2f5237314fd3452d51e38c7" +dependencies = [ + "alloy-primitives", + "alloy-sol-macro", + "const-hex", +] + +[[package]] +name = "anyhow" +version = "1.0.86" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "bitflags" +version = "2.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" + +[[package]] +name = "block-buffer" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" +dependencies = [ + "generic-array", +] + +[[package]] +name = "blst" +version = "0.3.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4378725facc195f1a538864863f6de233b500a8862747e7f165078a419d5e874" +dependencies = [ + "cc", + "glob", + "threadpool", + "zeroize", +] + +[[package]] +name = "byteorder" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "bytes" +version = "1.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8318a53db07bb3f8dca91a600466bdb3f2eaadeedfdbcf02e1accbad9271ba50" +dependencies = [ + "serde", +] + +[[package]] +name = "c-kzg" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0307f72feab3300336fb803a57134159f6e20139af1357f36c54cb90d8e8928" +dependencies = [ + "blst", + "cc", + "glob", + "hex", + "libc", + "serde", +] + +[[package]] +name = "cc" +version = "1.1.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57b6a275aa2903740dc87da01c62040406b8812552e97129a63ea8850a17c6e6" +dependencies = [ + "shlex", +] + +[[package]] +name = "cfg-if" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" + +[[package]] +name = "const-hex" +version = "1.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94fb8a24a26d37e1ffd45343323dc9fe6654ceea44c12f2fcb3d7ac29e610bc6" +dependencies = [ + "cfg-if", + "cpufeatures", + "hex", + "proptest", + "serde", +] + +[[package]] +name = "convert_case" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" + +[[package]] +name = "cpufeatures" +version = "0.2.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "51e852e6dc9a5bed1fae92dd2375037bf2b768725bf3be87811edee3249d09ad" +dependencies = [ + "libc", +] + +[[package]] +name = "crunchy" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" + +[[package]] +name = "crypto-common" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" +dependencies = [ + "generic-array", + "typenum", +] + +[[package]] +name = "derive_more" +version = "0.99.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f33878137e4dafd7fa914ad4e259e18a4e8e532b9617a2d0150262bf53abfce" +dependencies = [ + "convert_case", + "proc-macro2", + "quote", + "rustc_version", + "syn 2.0.76", +] + +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer", + "crypto-common", +] + +[[package]] +name = "dunce" +version = "1.0.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813" + +[[package]] +name = "equivalent" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" + +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", +] + +[[package]] +name = "glob" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" + +[[package]] +name = "hashbrown" +version = "0.14.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" +dependencies = [ + "ahash", + "allocator-api2", + "serde", +] + +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + +[[package]] +name = "hermit-abi" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" +dependencies = [ + "serde", +] + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "indexmap" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93ead53efc7ea8ed3cfb0c79fc8023fbb782a5432b52830b6518941cebe6505c" +dependencies = [ + "equivalent", + "hashbrown", +] + +[[package]] +name = "itoa" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" + +[[package]] +name = "lazy_static" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" + +[[package]] +name = "libc" +version = "0.2.158" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d8adc4bb1803a324070e64a98ae98f38934d91957a99cfb3a43dcbc01bc56439" + +[[package]] +name = "libm" +version = "0.2.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" + +[[package]] +name = "memchr" +version = "2.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", + "libm", +] + +[[package]] +name = "num_cpus" +version = "1.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" +dependencies = [ + "hermit-abi", + "libc", +] + +[[package]] +name = "once_cell" +version = "1.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" + +[[package]] +name = "paste" +version = "1.0.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" + +[[package]] +name = "ppv-lite86" +version = "0.2.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04" +dependencies = [ + "zerocopy", +] + +[[package]] +name = "proc-macro-error" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" +dependencies = [ + "proc-macro-error-attr", + "proc-macro2", + "quote", + "syn 1.0.109", + "version_check", +] + +[[package]] +name = "proc-macro-error-attr" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" +dependencies = [ + "proc-macro2", + "quote", + "version_check", +] + +[[package]] +name = "proc-macro2" +version = "1.0.86" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "proptest" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b4c2511913b88df1637da85cc8d96ec8e43a3f8bb8ccb71ee1ac240d6f3df58d" +dependencies = [ + "bitflags", + "num-traits", + "rand", + "rand_chacha", + "rand_xorshift", + "unarray", +] + +[[package]] +name = "quote" +version = "1.0.37" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b5b9d34b8991d19d98081b46eacdd8eb58c6f2b201139f7c5f643cc155a633af" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "rand" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" +dependencies = [ + "rand_core", +] + +[[package]] +name = "rand_chacha" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" +dependencies = [ + "ppv-lite86", + "rand_core", +] + +[[package]] +name = "rand_core" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" + +[[package]] +name = "rand_xorshift" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f" +dependencies = [ + "rand_core", +] + +[[package]] +name = "ruint" +version = "1.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c3cc4c2511671f327125da14133d0c5c5d137f006a1017a16f557bc85b16286" +dependencies = [ + "alloy-rlp", + "proptest", + "rand", + "ruint-macro", + "serde", + "valuable", + "zeroize", +] + +[[package]] +name = "ruint-macro" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48fd7bd8a6377e15ad9d42a8ec25371b94ddc67abe7c8b9127bec79bebaaae18" + +[[package]] +name = "rustc_version" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" +dependencies = [ + "semver", +] + +[[package]] +name = "ryu" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" + +[[package]] +name = "semver" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" + +[[package]] +name = "serde" +version = "1.0.209" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99fce0ffe7310761ca6bf9faf5115afbc19688edd00171d81b1bb1b116c63e09" +dependencies = [ + "serde_derive", +] + +[[package]] +name = "serde_derive" +version = "1.0.209" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a5831b979fd7b5439637af1752d535ff49f4860c0f341d1baeb6faf0f4242170" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.76", +] + +[[package]] +name = "serde_json" +version = "1.0.127" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8043c06d9f82bd7271361ed64f415fe5e12a77fdb52e573e7f06a516dea329ad" +dependencies = [ + "itoa", + "memchr", + "ryu", + "serde", +] + +[[package]] +name = "serde_repr" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.76", +] + +[[package]] +name = "serde_spanned" +version = "0.6.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eb5b1b31579f3811bf615c144393417496f152e12ac8b7663bf664f4a815306d" +dependencies = [ + "serde", +] + +[[package]] +name = "sha2" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" +dependencies = [ + "cfg-if", + "cpufeatures", + "digest", +] + +[[package]] +name = "shlex" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" + +[[package]] +name = "superchain" +version = "0.1.0" +dependencies = [ + "superchain-primitives", + "superchain-registry", +] + +[[package]] +name = "superchain-primitives" +version = "0.2.2" +dependencies = [ + "alloy-consensus", + "alloy-eips", + "alloy-genesis", + "alloy-primitives", + "alloy-sol-types", + "anyhow", + "serde", + "serde_repr", +] + +[[package]] +name = "superchain-registry" +version = "0.2.6" +dependencies = [ + "hashbrown", + "lazy_static", + "serde", + "serde_repr", + "superchain-primitives", + "toml", +] + +[[package]] +name = "syn" +version = "1.0.109" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" +dependencies = [ + "proc-macro2", + "unicode-ident", +] + +[[package]] +name = "syn" +version = "2.0.76" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "578e081a14e0cefc3279b0472138c513f37b41a08d5a3cca9b6e4e8ceb6cd525" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "syn-solidity" +version = "0.7.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c837dc8852cb7074e46b444afb81783140dab12c58867b49fb3898fbafedf7ea" +dependencies = [ + "paste", + "proc-macro2", + "quote", + "syn 2.0.76", +] + +[[package]] +name = "threadpool" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d050e60b33d41c19108b32cea32164033a9013fe3b46cbd4457559bfbf77afaa" +dependencies = [ + "num_cpus", +] + +[[package]] +name = "tiny-keccak" +version = "2.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c9d3793400a45f954c52e73d068316d76b6f4e36977e3fcebb13a2721e80237" +dependencies = [ + "crunchy", +] + +[[package]] +name = "toml" +version = "0.8.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1ed1f98e3fdc28d6d910e6737ae6ab1a93bf1985935a1193e68f93eeb68d24e" +dependencies = [ + "serde", + "serde_spanned", + "toml_datetime", + "toml_edit", +] + +[[package]] +name = "toml_datetime" +version = "0.6.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0dd7358ecb8fc2f8d014bf86f6f638ce72ba252a2c3a2572f2a795f1d23efb41" +dependencies = [ + "serde", +] + +[[package]] +name = "toml_edit" +version = "0.22.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "583c44c02ad26b0c3f3066fe629275e50627026c51ac2e595cca4c230ce1ce1d" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "winnow", +] + +[[package]] +name = "typenum" +version = "1.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" + +[[package]] +name = "unarray" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "valuable" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" + +[[package]] +name = "version_check" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" + +[[package]] +name = "winnow" +version = "0.6.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "68a9bda4691f099d435ad181000724da8e5899daa10713c2d432552b9ccd3a6f" +dependencies = [ + "memchr", +] + +[[package]] +name = "zerocopy" +version = "0.7.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0" +dependencies = [ + "byteorder", + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.76", +] + +[[package]] +name = "zeroize" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" +dependencies = [ + "zeroize_derive", +] + +[[package]] +name = "zeroize_derive" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.76", +] diff --git a/bindings/superchain/Cargo.toml b/bindings/superchain/Cargo.toml new file mode 100644 index 000000000..e570a7a1a --- /dev/null +++ b/bindings/superchain/Cargo.toml @@ -0,0 +1,35 @@ +[package] +name = "superchain" +description = "The Superchain Registry" +version = "0.1.0" +edition = "2021" +license = "MIT" +authors = ["OP Contributors"] +repository = "https://github.com/ethereum-optimism/superchain-registry" +homepage = "https://github.com/ethereum-optimism/superchain-registry/bindings/superchain" + +[package.metadata.docs.rs] +all-features = true +rustdoc-args = ["--cfg", "docsrs"] + +[dependencies] +superchain-primitives = { path = "../rust-primitives", version = "0.2.2", default-features = false } + +# `serde` is optional, but enabled by default +# Since superchain-registry requires `serde`, we mark it as optional +superchain-registry = { path = "../rust-bindings", version = "0.2.6", optional = true, default-feature = false } + +[features] +default = ["serde", "std"] + +serde = [ + "dep:superchain-registry", + "superchain-primitives/serde", +] + +std = [ + "serde", + "dep:superchain-registry", + "superchain-registry/std", + "superchain-primitives/std", +] diff --git a/bindings/superchain/Justfile b/bindings/superchain/Justfile new file mode 100644 index 000000000..bd92ae78f --- /dev/null +++ b/bindings/superchain/Justfile @@ -0,0 +1,61 @@ +set positional-arguments +alias t := tests +alias l := lint +alias f := fmt +alias b := build + +# default recipe to display help information +default: + @just --list + +# Runs everything needed for ci +ci: fmt lint tests + +# Run all tests +tests: test test-features test-docs + +# Formats +fmt: fmt-fix fmt-check + +# Lint the workspace for all available targets +lint: lint-source lint-source-features lint-docs + +# Build for the native target +build *args='': + cargo build --workspace --all $@ + +# Fixes the formatting +fmt-fix: + cargo +nightly fmt --all + +# Check the formatting +fmt-check: + cargo +nightly fmt --all -- --check + +# Lint the workspace +lint-source: fmt-check + cargo +nightly clippy --all --all-targets -- -D warnings + +# Lint the workspace +lint-source-features: fmt-check + cargo +nightly clippy --all --all-features --all-targets -- -D warnings + +# Lint the Rust documentation +lint-docs: + RUSTDOCFLAGS="-D warnings" cargo doc --all --no-deps --document-private-items + +# Test without features +test *args='': + cargo nextest run --all $@ + +# Test for the native target with all features +test-features *args='': + cargo nextest run --all --all-features $@ + +# Test the Rust documentation +test-docs: + cargo test --doc --all --locked + +# Release the crate +release: + cargo release publish --execute --no-confirm diff --git a/bindings/superchain/README.md b/bindings/superchain/README.md new file mode 100644 index 000000000..0f7327cf4 --- /dev/null +++ b/bindings/superchain/README.md @@ -0,0 +1,69 @@ +# `superchain` + +The `superchain` is an optionally `no_std` crate that provides core types +and bindings for the Superchain. + +It re-exports two crates: +- [`superchain-primitives`][scp] +- [`superchain-registry`][scr] _Only available if `serde` feature flag is enabled_ + +[`superchain-primitives`][scp] defines core types used in the `superchain-registry` +along with a few default values for core chains. + +[`superchain-registry`][scr] provides bindings to all chains in the `superchain`. + +## Usage + +Add the following to your `Cargo.toml`. + +```toml +[dependencies] +superchain = "0.1" +``` + +To make make `superchain` `no_std`, toggle `default-features` off like so. + +```toml +[dependencies] +superchain = { version = "0.1", default-features = false } +``` + +## Example + +[`superchain-registry`][scr] exposes lazily defined mappings from chain id +to chain configurations that the [`superchain`][sup] re-exports. Below +demonstrates getting the `RollupConfig` for OP Mainnet (Chain ID `10`). + +```rust +use superchain::ROLLUP_CONFIGS; + +let op_chain_id = 10; +let op_rollup_config = ROLLUP_CONFIGS.get(&op_chain_id); +println!("OP Mainnet Rollup Config: {:?}", op_rollup_config); +``` + +A mapping from chain id to `ChainConfig` is also available. + +```rust +use superchain::OPCHAINS; + +let op_chain_id = 10; +let op_chain_config = OPCHAINS.get(&op_chain_id); +println!("OP Mainnet Chain Config: {:?}", op_chain_config); +``` + +## Feature Flags + +- `serde`: Enables [`serde`][s] support for types and makes [`superchain-registry`][scr] types available. +- `std`: Uses the standard library to pull in environment variables. + + + +[sp]: ../rust-primitives + +[s]: https://crates.io/crates/serde +[sr]: https://github.com/ethereum-optimism/superchain-registry +[scr]: https://crates.io/crates/superchain-registry +[sup]: https://crates.io/crates/superchain +[scp]: https://crates.io/crates/superchain-primitives + diff --git a/bindings/superchain/src/lib.rs b/bindings/superchain/src/lib.rs new file mode 100644 index 000000000..d4a1f6006 --- /dev/null +++ b/bindings/superchain/src/lib.rs @@ -0,0 +1,18 @@ +#![doc = include_str!("../README.md")] +#![warn(missing_debug_implementations, missing_docs, rustdoc::all)] +#![deny(unused_must_use, rust_2018_idioms)] +#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(not(feature = "std"), no_std)] +#![cfg_attr(not(test), warn(unused_crate_dependencies))] + +/// Re-export types from [superchain_primitives]. +pub use superchain_primitives::*; + +/// Re-export [superchain_registry]. +#[cfg(feature = "serde")] +pub use superchain_registry; + +#[cfg(feature = "serde")] +pub use superchain_registry::{ + Chain, ChainList, HashMap, Registry, CHAINS, OPCHAINS, ROLLUP_CONFIGS, +}; diff --git a/justfile b/justfile index fbddcf6a9..dcea90953 100644 --- a/justfile +++ b/justfile @@ -81,18 +81,22 @@ remove-chain SUPERCHAIN_TARGET CHAIN: cargo-tests: just bindings/rust-primitives/tests just bindings/rust-bindings/tests + just bindings/superchain/tests # Run cargo lints cargo-lint: just bindings/rust-primitives/lint just bindings/rust-bindings/lint + just bindings/superchain/lint # Cargo build cargo-build: just bindings/rust-primitives/build just bindings/rust-bindings/build + just bindings/superchain/build # Release release: just bindings/rust-primitives/release just bindings/rust-bindings/release + just bindings/superchain/release From 0966106fd3a355a8702052cfa023cd81c4ae9f66 Mon Sep 17 00:00:00 2001 From: refcell Date: Tue, 27 Aug 2024 18:24:58 -0400 Subject: [PATCH 03/30] fix(bindings): Disable Default Features in superchain dep (#512) * fix(bindings): superchain registry import * fix: alias prefices --- .github/workflows/release.yml | 3 +++ bindings/rust-bindings/Cargo.lock | 1 - bindings/rust-bindings/Cargo.toml | 1 - bindings/rust-bindings/src/lib.rs | 1 + bindings/rust-primitives/src/lib.rs | 1 + bindings/superchain/Cargo.lock | 3 +-- bindings/superchain/Cargo.toml | 4 ++-- justfile | 10 ++++++++++ 8 files changed, 18 insertions(+), 6 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ed49415e3..e6ae78779 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -23,3 +23,6 @@ jobs: - name: Release superchain-registry crate run: just bindings/rust-bindings/release continue-on-error: true + - name: Release superchain crate + run: just bindings/superchain/release + continue-on-error: true diff --git a/bindings/rust-bindings/Cargo.lock b/bindings/rust-bindings/Cargo.lock index 0dcc51067..943762fb2 100644 --- a/bindings/rust-bindings/Cargo.lock +++ b/bindings/rust-bindings/Cargo.lock @@ -667,7 +667,6 @@ dependencies = [ "hashbrown", "lazy_static", "serde", - "serde_repr", "superchain-primitives", "toml", ] diff --git a/bindings/rust-bindings/Cargo.toml b/bindings/rust-bindings/Cargo.toml index 86e1a4105..6b060c677 100644 --- a/bindings/rust-bindings/Cargo.toml +++ b/bindings/rust-bindings/Cargo.toml @@ -19,7 +19,6 @@ superchain-primitives = { path = "../rust-primitives", version = "0.2.2", defaul # Serialization serde = { version = "1.0.203", default-features = false, features = ["derive", "alloc"] } toml = { version = "0.8.14" } -serde_repr = "0.1" [dev-dependencies] alloy-primitives = { version = "0.7.1", default-features = false } diff --git a/bindings/rust-bindings/src/lib.rs b/bindings/rust-bindings/src/lib.rs index 2c62965b7..fb342a9c2 100644 --- a/bindings/rust-bindings/src/lib.rs +++ b/bindings/rust-bindings/src/lib.rs @@ -2,6 +2,7 @@ #![warn(missing_debug_implementations, missing_docs, rustdoc::all)] #![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(not(test), warn(unused_crate_dependencies))] #![cfg_attr(not(feature = "std"), no_std)] extern crate alloc; diff --git a/bindings/rust-primitives/src/lib.rs b/bindings/rust-primitives/src/lib.rs index 6ef8949b9..b10f44ba2 100644 --- a/bindings/rust-primitives/src/lib.rs +++ b/bindings/rust-primitives/src/lib.rs @@ -2,6 +2,7 @@ #![warn(missing_debug_implementations, missing_docs, rustdoc::all)] #![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(not(test), warn(unused_crate_dependencies))] #![cfg_attr(not(feature = "std"), no_std)] extern crate alloc; diff --git a/bindings/superchain/Cargo.lock b/bindings/superchain/Cargo.lock index a4ee9ec06..24ce6ab29 100644 --- a/bindings/superchain/Cargo.lock +++ b/bindings/superchain/Cargo.lock @@ -666,7 +666,7 @@ checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" [[package]] name = "superchain" -version = "0.1.0" +version = "0.1.1" dependencies = [ "superchain-primitives", "superchain-registry", @@ -693,7 +693,6 @@ dependencies = [ "hashbrown", "lazy_static", "serde", - "serde_repr", "superchain-primitives", "toml", ] diff --git a/bindings/superchain/Cargo.toml b/bindings/superchain/Cargo.toml index e570a7a1a..59caef962 100644 --- a/bindings/superchain/Cargo.toml +++ b/bindings/superchain/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "superchain" description = "The Superchain Registry" -version = "0.1.0" +version = "0.1.1" edition = "2021" license = "MIT" authors = ["OP Contributors"] @@ -17,7 +17,7 @@ superchain-primitives = { path = "../rust-primitives", version = "0.2.2", defaul # `serde` is optional, but enabled by default # Since superchain-registry requires `serde`, we mark it as optional -superchain-registry = { path = "../rust-bindings", version = "0.2.6", optional = true, default-feature = false } +superchain-registry = { path = "../rust-bindings", version = "0.2.6", optional = true, default-features = false } [features] default = ["serde", "std"] diff --git a/justfile b/justfile index dcea90953..46186d2bb 100644 --- a/justfile +++ b/justfile @@ -1,4 +1,8 @@ set positional-arguments +alias ct := cargo-tests +alias cl := cargo-lint +alias cf := cargo-format +alias cb := cargo-build # Adding a chain add-chain: @@ -83,6 +87,12 @@ cargo-tests: just bindings/rust-bindings/tests just bindings/superchain/tests +# Run cargo format +cargo-format: + just bindings/rust-primitives/fmt + just bindings/rust-bindings/fmt + just bindings/superchain/fmt + # Run cargo lints cargo-lint: just bindings/rust-primitives/lint From 3bd2566cf904355a14c2037b4b7d5ac7ef026eb2 Mon Sep 17 00:00:00 2001 From: George Knee Date: Wed, 28 Aug 2024 13:37:31 +0100 Subject: [PATCH 04/30] modify promotion test notification (#516) --- .circleci/config.yml | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7dd095754..46b749d63 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -142,7 +142,32 @@ jobs: - run: name: run validation checks command: just promotion-test - - notify-failures-on-main: + - slack/notify: + event: always + custom: | + { + "blocks": [ + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": ":control_knobs: The daily report on standard candidate chains is ready!" + } + }, + { + "type": "divider" + }, + { + "type": "context", + "elements": [ + { + "type": "mrkdwn", + "text": "👀 Click the link to see what validation checks would fail if all candidate chains were promoted to standard (and exclusions removed)." + } + ] + } + ] + } channel: C07GZVCCUS0 # to slack channel `notify-superchain-promotion-failures` publish-bot: environment: From 1bace9f00e6a76f5c40fb8db2f66fcae5a593901 Mon Sep 17 00:00:00 2001 From: George Knee Date: Wed, 28 Aug 2024 13:40:34 +0100 Subject: [PATCH 05/30] Add silence for OP Mainnet Optimism_Portal_2_Params (#515) * add silence for OP Mainnet Optimism_Portal_2_Params * fix comment * rework silences mechanism * pull Granite time from superchain go module * just lint-all --- validation/exclusions_test.go | 10 ++++++++++ validation/genesis/optimism-temporary | 1 + 2 files changed, 11 insertions(+) create mode 160000 validation/genesis/optimism-temporary diff --git a/validation/exclusions_test.go b/validation/exclusions_test.go index add98ff50..6c788156b 100644 --- a/validation/exclusions_test.go +++ b/validation/exclusions_test.go @@ -3,6 +3,7 @@ package validation import ( "regexp" "testing" + "time" "github.com/ethereum-optimism/superchain-registry/superchain" "github.com/stretchr/testify/require" @@ -17,6 +18,9 @@ func skipIfExcluded(t *testing.T, chainID uint64) { if matches && exclusions[pattern][chainID] { t.Skip("Excluded!") } + if matches && silences[pattern][chainID].After(time.Now()) { + t.Skipf("Silenced until %s", silences[pattern][chainID].String()) + } } } @@ -59,6 +63,12 @@ var exclusions = map[string]map[uint64]bool{ }, } +var silences = map[string]map[uint64]time.Time{ + "Optimism_Portal_2_Params": { + 10: time.Unix(int64(*superchain.OPChains[10].HardForkConfiguration.GraniteTime), 0), // mainnet/op silenced until Granite activates + }, +} + func TestExclusions(t *testing.T) { for name, v := range exclusions { for k := range v { diff --git a/validation/genesis/optimism-temporary b/validation/genesis/optimism-temporary new file mode 160000 index 000000000..d80c145e0 --- /dev/null +++ b/validation/genesis/optimism-temporary @@ -0,0 +1 @@ +Subproject commit d80c145e0acf23a49c6a6588524f57e32e33b91c From 4e6edcb7d36ca61afc3fe05826ebfecb406784a6 Mon Sep 17 00:00:00 2001 From: George Knee Date: Wed, 28 Aug 2024 15:49:51 +0100 Subject: [PATCH 06/30] Store Optimism Config in config toml files (#510) * capture optimism config when compressing genesis * remove submodule * move types down into superchain module * lint * pull in op-geth from https://github.com/ethereum-optimism/op-geth/pull/371 * migrate existing genesis files to include default Optimism values EIP1559Elasticity: 6, EIP1559Denominator: 50, EIP1559DenominatorCanyon: u64ptr(250) special case for base sepolia, overrides elasticity paramter to be 10 Our diff bot should pick up any mistakes in this migration, we are aiming for a net zero overall diff to the effective genesis files * zora sepolia: set EIP1559DenominatorCanyon: nil We have the actual genesis of this chain on hand, so we know the correct value of this parameter * update op-geth * remove temporary workaround code * break line for readability * move Optimism config from genesis .json.gz to chain config toml files * update op-geth * fix add-chain e2e test * update chain configs to include genesis.config.optimism field * restore indentation * fix value * just codegen * add genesis.config.optimism to devnets * just codegen * Update superchain/configs/sepolia/zora.toml * fix: rust-bindings codegen * un-nest Optimism config * update op-geth * update config files with new optimism structure * just codegen * remove duplicate data * fixup op sepolia (missed it before) * just codegen --------- Co-authored-by: refcell --- add-chain/cmd/check-genesis.go | 9 --- add-chain/cmd/compress-genesis.go | 21 +----- add-chain/config/config.go | 10 +++ add-chain/e2e_test.go | 1 + add-chain/go.mod | 14 ++-- add-chain/go.sum | 24 +++---- add-chain/main.go | 5 +- add-chain/testdata/.env.test | 1 + .../configs/sepolia/expected_altda.toml | 4 ++ .../configs/sepolia/expected_baseline.toml | 4 ++ .../sepolia/expected_baseline_legacy.toml | 4 ++ .../configs/sepolia/expected_faultproofs.toml | 4 ++ .../sepolia/expected_standard-candidate.toml | 4 ++ .../configs/sepolia/expected_zorasep.toml | 4 ++ add-chain/utils/utils.go | 24 +++++++ bindings/rust-bindings/etc/configs.toml | 68 +++++++++++++++++++ superchain/configs/mainnet/base.toml | 5 ++ superchain/configs/mainnet/lyra.toml | 5 ++ superchain/configs/mainnet/metal.toml | 5 ++ superchain/configs/mainnet/mode.toml | 5 ++ superchain/configs/mainnet/op.toml | 5 ++ superchain/configs/mainnet/orderly.toml | 5 ++ superchain/configs/mainnet/race.toml | 5 ++ superchain/configs/mainnet/tbn.toml | 10 +++ superchain/configs/mainnet/zora.toml | 5 ++ .../configs/sepolia-dev-0/base-devnet-0.toml | 5 ++ .../sepolia-dev-0/oplabs-devnet-0.toml | 5 ++ superchain/configs/sepolia/base.toml | 5 ++ superchain/configs/sepolia/metal.toml | 5 ++ superchain/configs/sepolia/mode.toml | 5 ++ superchain/configs/sepolia/op.toml | 5 ++ superchain/configs/sepolia/race.toml | 5 ++ superchain/configs/sepolia/zora.toml | 5 ++ superchain/superchain.go | 7 ++ validation/go.mod | 14 ++-- validation/go.sum | 24 +++---- 36 files changed, 270 insertions(+), 66 deletions(-) create mode 100644 add-chain/utils/utils.go diff --git a/add-chain/cmd/check-genesis.go b/add-chain/cmd/check-genesis.go index 0d77dd4c7..8b5ebf152 100644 --- a/add-chain/cmd/check-genesis.go +++ b/add-chain/cmd/check-genesis.go @@ -36,15 +36,6 @@ var CheckGenesisCmd = cli.Command{ return fmt.Errorf("failed to load genesis via op-geth: ensure chainId has already been added to registry: %w", err) } - // Exceptions for testing - if localGenesis.Config.Optimism != nil { - // this value is always hardcoded in op-geth to 250. Need to updated op-geth to - // conditionally set the value (if canyon is activated) to remove the exception - // https://github.com/ethereum-optimism/op-geth/issues/346 - twofifty := uint64(250) - localGenesis.Config.Optimism.EIP1559DenominatorCanyon = &twofifty - } - opts := cmp.Options{cmpopts.IgnoreUnexported(big.Int{})} if diff := cmp.Diff(localGenesis, gethGenesis, opts...); diff != "" { return fmt.Errorf("local genesis.json (-) does not match config generated by op-geth (+): %s", diff) diff --git a/add-chain/cmd/compress-genesis.go b/add-chain/cmd/compress-genesis.go index bac05196a..4b47e97d7 100644 --- a/add-chain/cmd/compress-genesis.go +++ b/add-chain/cmd/compress-genesis.go @@ -13,6 +13,7 @@ import ( "github.com/ethereum-optimism/optimism/op-service/jsonutil" "github.com/ethereum-optimism/superchain-registry/add-chain/flags" + "github.com/ethereum-optimism/superchain-registry/add-chain/utils" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core" @@ -55,7 +56,7 @@ var CompressGenesisCmd = cli.Command{ // Archive nodes that depend on this historical state should instantiate the chain from a full genesis dump // with allocation data, or datadir. genesisHeaderPath := ctx.Path(flags.L2GenesisHeaderFlag.Name) - genesisHeader, err := loadJSON[types.Header](genesisHeaderPath) + genesisHeader, err := utils.LoadJSON[types.Header](genesisHeaderPath) if err != nil { return fmt.Errorf("genesis-header %q failed to load: %w", genesisHeaderPath, err) } @@ -94,7 +95,7 @@ var CompressGenesisCmd = cli.Command{ return nil } - genesis, err := loadJSON[core.Genesis](genesisPath) + genesis, err := utils.LoadJSON[core.Genesis](genesisPath) if err != nil { return fmt.Errorf("failed to load L2 genesis: %w", err) } @@ -219,22 +220,6 @@ type Genesis struct { StateHash *common.Hash `json:"stateHash,omitempty"` } -func loadJSON[X any](inputPath string) (*X, error) { - if inputPath == "" { - return nil, errors.New("no path specified") - } - f, err := os.OpenFile(inputPath, os.O_RDONLY, 0) - if err != nil { - return nil, fmt.Errorf("failed to open file %q: %w", inputPath, err) - } - defer f.Close() - var obj X - if err := json.NewDecoder(f).Decode(&obj); err != nil { - return nil, fmt.Errorf("failed to decode file %q: %w", inputPath, err) - } - return &obj, nil -} - func writeGzipJSON(outputPath string, value any) error { fmt.Printf("using output gzip filepath: %s\n", outputPath) f, err := os.OpenFile(outputPath, os.O_WRONLY|os.O_CREATE|os.O_TRUNC, 0o755) diff --git a/add-chain/config/config.go b/add-chain/config/config.go index bc2548563..e95fe6a0c 100644 --- a/add-chain/config/config.go +++ b/add-chain/config/config.go @@ -11,7 +11,9 @@ import ( "time" "github.com/BurntSushi/toml" + "github.com/ethereum/go-ethereum/core" + "github.com/ethereum-optimism/superchain-registry/add-chain/utils" "github.com/ethereum-optimism/superchain-registry/superchain" ) @@ -19,6 +21,7 @@ import ( // explicitly setting some additional fields to input argument values func ConstructChainConfig( inputFilePath, + genesisPath, chainName, publicRPC, sequencerRPC, @@ -41,6 +44,13 @@ func ConstructChainConfig( return superchain.ChainConfig{}, fmt.Errorf("error with json altDA config: %w", err) } + genesis, err := utils.LoadJSON[core.Genesis](genesisPath) + if err != nil { + return superchain.ChainConfig{}, fmt.Errorf("failed to load L2 genesis: %w", err) + } + + chainConfig.Optimism = (*superchain.OptimismConfig)(genesis.Config.Optimism) + chainConfig.Name = chainName chainConfig.PublicRPC = publicRPC chainConfig.SequencerRPC = sequencerRPC diff --git a/add-chain/e2e_test.go b/add-chain/e2e_test.go index 885cd1fcd..138ed2b71 100644 --- a/add-chain/e2e_test.go +++ b/add-chain/e2e_test.go @@ -88,6 +88,7 @@ func TestAddChain_Main(t *testing.T) { "--chain-name=" + tt.chainName, "--chain-short-name=" + tt.chainShortName, "--rollup-config=" + tt.rollupConfigFile, + "--genesis=" + "./testdata/monorepo/op-node/genesis_zorasep.json", "--deployments-dir=" + tt.deploymentsDir, "--standard-chain-candidate=" + strconv.FormatBool(tt.standardChainCandidate), } diff --git a/add-chain/go.mod b/add-chain/go.mod index 27e0efb28..75447d3f2 100644 --- a/add-chain/go.mod +++ b/add-chain/go.mod @@ -4,12 +4,12 @@ go 1.21 replace github.com/ethereum-optimism/superchain-registry/superchain => ../superchain -replace github.com/ethereum/go-ethereum => github.com/ethereum-optimism/op-geth v1.101407.0-rc.1.0.20240812224053-8d99ca68bb1a +replace github.com/ethereum/go-ethereum => github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240827194518-1071ac1284b8 require ( github.com/BurntSushi/toml v1.4.0 github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813 - github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240814192743-ea7e768a02a6 + github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240827194108-65ec82d9a1b2 github.com/ethereum/go-ethereum v1.14.7 github.com/google/go-cmp v0.6.0 github.com/joho/godotenv v1.5.1 @@ -23,11 +23,12 @@ require ( github.com/VictoriaMetrics/fastcache v1.12.2 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/bits-and-blooms/bitset v1.10.0 // indirect - github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect + github.com/btcsuite/btcd/btcec/v2 v2.3.4 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/cockroachdb/errors v1.11.3 // indirect + github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce // indirect github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect - github.com/cockroachdb/pebble v0.0.0-20231018212520-f6cde3fc2fa4 // indirect + github.com/cockroachdb/pebble v1.1.2 // indirect github.com/cockroachdb/redact v1.1.5 // indirect github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect github.com/consensys/bavard v0.1.13 // indirect @@ -40,7 +41,6 @@ require ( github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 // indirect github.com/ethereum/c-kzg-4844 v1.0.0 // indirect github.com/ethereum/go-verkle v0.1.1-0.20240306133620-7d920df305f0 // indirect - github.com/fjl/memsize v0.0.2 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect github.com/getsentry/sentry-go v0.27.0 // indirect github.com/go-ole/go-ole v1.3.0 // indirect @@ -87,11 +87,11 @@ require ( golang.org/x/mod v0.20.0 // indirect golang.org/x/net v0.27.0 // indirect golang.org/x/sync v0.8.0 // indirect - golang.org/x/sys v0.23.0 // indirect + golang.org/x/sys v0.24.0 // indirect golang.org/x/term v0.23.0 // indirect golang.org/x/text v0.17.0 // indirect golang.org/x/time v0.6.0 // indirect - google.golang.org/protobuf v1.34.1 // indirect + google.golang.org/protobuf v1.34.2 // indirect gopkg.in/natefinch/lumberjack.v2 v2.2.1 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect rsc.io/tmplfunc v0.0.3 // indirect diff --git a/add-chain/go.sum b/add-chain/go.sum index 2cffa57e3..7d7db161f 100644 --- a/add-chain/go.sum +++ b/add-chain/go.sum @@ -14,8 +14,8 @@ github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6r github.com/bits-and-blooms/bitset v1.10.0 h1:ePXTeiPEazB5+opbv5fr8umg2R/1NlzgDsyepwsSr88= github.com/bits-and-blooms/bitset v1.10.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= github.com/btcsuite/btcd v0.24.2 h1:aLmxPguqxza+4ag8R1I2nnJjSu2iFn/kqtHTIImswcY= -github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= -github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= +github.com/btcsuite/btcd/btcec/v2 v2.3.4 h1:3EJjcN70HCu/mwqlUsGK8GcNVyLVxFDlWurTXGPFfiQ= +github.com/btcsuite/btcd/btcec/v2 v2.3.4/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= github.com/btcsuite/btcd/chaincfg/chainhash v1.1.0 h1:59Kx4K6lzOW5w6nFlA0v5+lk/6sjybR934QNHSJZPTQ= github.com/btcsuite/btcd/chaincfg/chainhash v1.1.0/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= github.com/cespare/cp v0.1.0 h1:SE+dxFebS7Iik5LK0tsi1k9ZCxEaFX4AjQmoyA+1dJk= @@ -30,10 +30,12 @@ github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f h1:otljaY github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= github.com/cockroachdb/errors v1.11.3 h1:5bA+k2Y6r+oz/6Z/RFlNeVCesGARKuC6YymtcDrbC/I= github.com/cockroachdb/errors v1.11.3/go.mod h1:m4UIW4CDjx+R5cybPsNrRbreomiFqt8o1h1wUVazSd8= +github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce h1:giXvy4KSc/6g/esnpM7Geqxka4WSqI1SZc7sMJFd3y4= +github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce/go.mod h1:9/y3cnZ5GKakj/H4y9r9GTjCvAFta7KLgSHPJJYc52M= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZeQy818SGhaone5OnYfxFR/+AzdY3sf5aE= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= -github.com/cockroachdb/pebble v0.0.0-20231018212520-f6cde3fc2fa4 h1:PuHFhOUMnD62r80dN+Ik5qco2drekgsUSVdcHsvllec= -github.com/cockroachdb/pebble v0.0.0-20231018212520-f6cde3fc2fa4/go.mod h1:sEHm5NOXxyiAoKWhoFxT8xMgd/f3RA6qUqQ1BXKrh2E= +github.com/cockroachdb/pebble v1.1.2 h1:CUh2IPtR4swHlEj48Rhfzw6l/d0qA31fItcIszQVIsA= +github.com/cockroachdb/pebble v1.1.2/go.mod h1:4exszw1r40423ZsmkG/09AFEG83I0uDgfujJdbL6kYU= github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 h1:zuQyyAKVxetITBuuhv3BI9cMrmStnpT18zmgmTxunpo= @@ -59,16 +61,14 @@ github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5il github.com/decred/dcrd/crypto/blake256 v1.0.1/go.mod h1:2OfgNZ5wDpcsFmHmCK5gZTPcCXqlm2ArzUIkw9czNJo= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 h1:rpfIENRNNilwHwZeG5+P150SMrnNEcHYvcCuK6dPZSg= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= -github.com/ethereum-optimism/op-geth v1.101407.0-rc.1.0.20240812224053-8d99ca68bb1a h1:OK3wB7HbdhCneSowC1XZusHaLIVdXoRLuCWgXp5Tjuc= -github.com/ethereum-optimism/op-geth v1.101407.0-rc.1.0.20240812224053-8d99ca68bb1a/go.mod h1:9pT+bF20XwCBE7WkjfRSsCg6RN6Njdbr924DtQ3+geY= +github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240827194518-1071ac1284b8 h1:herYQxIOCZzBNAIClH0BP/+1BAXIn5bz0vRYH9bdgug= +github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240827194518-1071ac1284b8/go.mod h1:WBZxPjS4MTFLiFGEfBngof6KwdIU6zZ4t00B8zLJwDE= github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813 h1:g1eUt4iB+v+FGdO7WAI17SpVahsrC6S9HGO0ceAd8Ec= github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813/go.mod h1:LTZIluX+26O0GHlwnFdPIUX04OUqcVDdThjRDsALYUY= github.com/ethereum/c-kzg-4844 v1.0.0 h1:0X1LBXxaEtYD9xsyj9B9ctQEZIpnvVDeoBx8aHEwTNA= github.com/ethereum/c-kzg-4844 v1.0.0/go.mod h1:VewdlzQmpT5QSrVhbBuGoCdFJkpaJlO1aQputP83wc0= github.com/ethereum/go-verkle v0.1.1-0.20240306133620-7d920df305f0 h1:KrE8I4reeVvf7C1tm8elRjj4BdscTYzz/WAbYyf/JI4= github.com/ethereum/go-verkle v0.1.1-0.20240306133620-7d920df305f0/go.mod h1:D9AJLVXSyZQXJQVk8oh1EwjISE+sJTn2duYIZC0dy3w= -github.com/fjl/memsize v0.0.2 h1:27txuSD9or+NZlnOWdKUxeBzTAUkWCVh+4Gf2dWFOzA= -github.com/fjl/memsize v0.0.2/go.mod h1:VvhXpOYNQvB+uIk2RvXzuaQtkQJzzIx6lSBe1xv7hi0= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/fsnotify/fsnotify v1.5.4/go.mod h1:OVB6XrOHzAwXMpEM7uPOzcehqUV2UqJxmVXmkdnm1bU= @@ -286,8 +286,8 @@ golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.11.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.23.0 h1:YfKFowiIMvtgl1UERQoTPPToxltDeZfbj4H7dVUCwmM= -golang.org/x/sys v0.23.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.24.0 h1:Twjiwq9dn6R1fQcyiK+wQyHWfaz/BJB+YIpzU/Cv3Xg= +golang.org/x/sys v0.24.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.23.0 h1:F6D4vR+EHoL9/sWAWgAR1H2DcHr4PareCbAaCo1RpuU= @@ -318,8 +318,8 @@ google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzi google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.34.1 h1:9ddQBjfCyZPOHPUiPxpYESBLc+T8P3E+Vo4IbKZgFWg= -google.golang.org/protobuf v1.34.1/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= +google.golang.org/protobuf v1.34.2 h1:6xV6lTsCfpGD21XK49h7MhtcApnLqkfYgPcdHftf6hg= +google.golang.org/protobuf v1.34.2/go.mod h1:qYOHts0dSfpeUzUFpOMr/WGzszTmLH+DiWniOlNbLDw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= diff --git a/add-chain/main.go b/add-chain/main.go index b93e9f637..ea824db11 100644 --- a/add-chain/main.go +++ b/add-chain/main.go @@ -32,6 +32,7 @@ var app = &cli.App{ flags.ChainNameFlag, flags.ChainShortNameFlag, flags.RollupConfigFlag, + flags.GenesisFlag, flags.DeploymentsDirFlag, flags.StandardChainCandidateFlag, }, @@ -87,6 +88,7 @@ func entrypoint(ctx *cli.Context) error { chainName := ctx.String(flags.ChainNameFlag.Name) rollupConfigPath := ctx.String(flags.RollupConfigFlag.Name) + genesisPath := ctx.String(flags.GenesisFlag.Name) deploymentsDir := ctx.String(flags.DeploymentsDirFlag.Name) chainShortName := ctx.String(flags.ChainShortNameFlag.Name) if chainShortName == "" { @@ -107,6 +109,7 @@ func entrypoint(ctx *cli.Context) error { fmt.Printf("Monorepo dir: %s\n", monorepoDir) fmt.Printf("Deployments directory: %s\n", deploymentsDir) fmt.Printf("Rollup config filepath: %s\n", rollupConfigPath) + fmt.Printf("Genesis filepath: %s\n", genesisPath) fmt.Printf("Public RPC endpoint: %s\n", publicRPC) fmt.Printf("Sequencer RPC endpoint: %s\n", sequencerRPC) fmt.Printf("Block Explorer: %s\n", explorer) @@ -134,7 +137,7 @@ func entrypoint(ctx *cli.Context) error { return fmt.Errorf("failed to infer fault proofs status of chain: %w", err) } - rollupConfig, err := config.ConstructChainConfig(rollupConfigPath, chainName, publicRPC, sequencerRPC, explorer, superchainLevel, standardChainCandidate) + rollupConfig, err := config.ConstructChainConfig(rollupConfigPath, genesisPath, chainName, publicRPC, sequencerRPC, explorer, superchainLevel, standardChainCandidate) if err != nil { return fmt.Errorf("failed to construct rollup config: %w", err) } diff --git a/add-chain/testdata/.env.test b/add-chain/testdata/.env.test index d5291cdde..0f92df81a 100644 --- a/add-chain/testdata/.env.test +++ b/add-chain/testdata/.env.test @@ -4,6 +4,7 @@ SCR_SUPERCHAIN_TARGET=sepolia # L1 chain name SCR_MONOREPO_DIR=./testdata/monorepo SCR_DEPLOYMENTS_DIR=${SCR_MONOREPO_DIR}/deployments SCR_ROLLUP_CONFIG=${SCR_MONOREPO_DIR}/op-node/rollup.json +SCR_GENESIS=${SCR_MONOREPO_DIR}/op-node/genesis.json SCR_PUBLIC_RPC="http://awe.some.rpc" # L2 RPC URL SCR_SEQUENCER_RPC="http://awe.some.seq.rpc" SCR_EXPLORER="https://awesomescan.org" # L2 block explorer URL diff --git a/add-chain/testdata/superchain/configs/sepolia/expected_altda.toml b/add-chain/testdata/superchain/configs/sepolia/expected_altda.toml index 7e1edf2bc..ed480abfc 100644 --- a/add-chain/testdata/superchain/configs/sepolia/expected_altda.toml +++ b/add-chain/testdata/superchain/configs/sepolia/expected_altda.toml @@ -13,6 +13,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "alt-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + [alt_da] da_challenge_contract_address = "0x3333333333333333333300000000000000000000" da_challenge_window = 5555555 diff --git a/add-chain/testdata/superchain/configs/sepolia/expected_baseline.toml b/add-chain/testdata/superchain/configs/sepolia/expected_baseline.toml index e843b13a0..15db6c364 100644 --- a/add-chain/testdata/superchain/configs/sepolia/expected_baseline.toml +++ b/add-chain/testdata/superchain/configs/sepolia/expected_baseline.toml @@ -12,6 +12,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + [genesis] l2_time = 1713792864 [genesis.l1] diff --git a/add-chain/testdata/superchain/configs/sepolia/expected_baseline_legacy.toml b/add-chain/testdata/superchain/configs/sepolia/expected_baseline_legacy.toml index d51a0b70c..f36f29feb 100644 --- a/add-chain/testdata/superchain/configs/sepolia/expected_baseline_legacy.toml +++ b/add-chain/testdata/superchain/configs/sepolia/expected_baseline_legacy.toml @@ -12,6 +12,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + [genesis] l2_time = 1713792864 [genesis.l1] diff --git a/add-chain/testdata/superchain/configs/sepolia/expected_faultproofs.toml b/add-chain/testdata/superchain/configs/sepolia/expected_faultproofs.toml index d7f83c9a7..1a4090a70 100644 --- a/add-chain/testdata/superchain/configs/sepolia/expected_faultproofs.toml +++ b/add-chain/testdata/superchain/configs/sepolia/expected_faultproofs.toml @@ -13,6 +13,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + [genesis] l2_time = 1706484048 [genesis.l1] diff --git a/add-chain/testdata/superchain/configs/sepolia/expected_standard-candidate.toml b/add-chain/testdata/superchain/configs/sepolia/expected_standard-candidate.toml index 80297d48c..8d9af5994 100644 --- a/add-chain/testdata/superchain/configs/sepolia/expected_standard-candidate.toml +++ b/add-chain/testdata/superchain/configs/sepolia/expected_standard-candidate.toml @@ -13,6 +13,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + [genesis] l2_time = 1713792864 [genesis.l1] diff --git a/add-chain/testdata/superchain/configs/sepolia/expected_zorasep.toml b/add-chain/testdata/superchain/configs/sepolia/expected_zorasep.toml index 4a7c4bde1..d88bd857c 100644 --- a/add-chain/testdata/superchain/configs/sepolia/expected_zorasep.toml +++ b/add-chain/testdata/superchain/configs/sepolia/expected_zorasep.toml @@ -11,6 +11,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + [genesis] l2_time = 1698080004 [genesis.l1] diff --git a/add-chain/utils/utils.go b/add-chain/utils/utils.go new file mode 100644 index 000000000..747cc6ac0 --- /dev/null +++ b/add-chain/utils/utils.go @@ -0,0 +1,24 @@ +package utils + +import ( + "encoding/json" + "errors" + "fmt" + "os" +) + +func LoadJSON[X any](inputPath string) (*X, error) { + if inputPath == "" { + return nil, errors.New("no path specified") + } + f, err := os.OpenFile(inputPath, os.O_RDONLY, 0) + if err != nil { + return nil, fmt.Errorf("failed to open file %q: %w", inputPath, err) + } + defer f.Close() + var obj X + if err := json.NewDecoder(f).Decode(&obj); err != nil { + return nil, fmt.Errorf("failed to decode file %q: %w", inputPath, err) + } + return &obj, nil +} diff --git a/bindings/rust-bindings/etc/configs.toml b/bindings/rust-bindings/etc/configs.toml index a492c4675..2ab7f8043 100644 --- a/bindings/rust-bindings/etc/configs.toml +++ b/bindings/rust-bindings/etc/configs.toml @@ -31,6 +31,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1686068903 [superchains.chains.genesis.l1] @@ -89,6 +93,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1696608227 [superchains.chains.genesis.l1] @@ -145,6 +153,10 @@ max_sequencer_drift = 600 data_availability_type = "eth-da" gas_paying_token = "0x04E9D7e336f79Cdab911b06133D3Ca2Cd0721ce3" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1719397463 [superchains.chains.genesis.l1] @@ -203,6 +215,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1700021615 [superchains.chains.genesis.l1] @@ -262,6 +278,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1711563515 [superchains.chains.genesis.l1] @@ -317,6 +337,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1720421591 [superchains.chains.genesis.l1] @@ -376,6 +400,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1686789347 [superchains.chains.genesis.l1] @@ -435,6 +463,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1700167583 [superchains.chains.genesis.l1] @@ -494,6 +526,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1686693839 [superchains.chains.genesis.l1] @@ -564,6 +600,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1687867932 [superchains.chains.genesis.l1] @@ -620,6 +660,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1708129620 [superchains.chains.genesis.l1] @@ -675,6 +719,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1719646560 [superchains.chains.genesis.l1] @@ -734,6 +782,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 10 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1695768288 [superchains.chains.genesis.l1] @@ -792,6 +844,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1691802540 [superchains.chains.genesis.l1] @@ -851,6 +907,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1698080004 [superchains.chains.genesis.l1] @@ -920,6 +980,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1706484048 [superchains.chains.genesis.l1] @@ -978,6 +1042,10 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [superchains.chains.genesis] l2_time = 1695433056 [superchains.chains.genesis.l1] diff --git a/superchain/configs/mainnet/base.toml b/superchain/configs/mainnet/base.toml index 5f9362b3e..c6056fd10 100644 --- a/superchain/configs/mainnet/base.toml +++ b/superchain/configs/mainnet/base.toml @@ -16,6 +16,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1686789347 [genesis.l1] diff --git a/superchain/configs/mainnet/lyra.toml b/superchain/configs/mainnet/lyra.toml index 18dc06647..fd13ab8ff 100644 --- a/superchain/configs/mainnet/lyra.toml +++ b/superchain/configs/mainnet/lyra.toml @@ -15,6 +15,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1700021615 [genesis.l1] diff --git a/superchain/configs/mainnet/metal.toml b/superchain/configs/mainnet/metal.toml index 3de52a791..ade5f41b6 100644 --- a/superchain/configs/mainnet/metal.toml +++ b/superchain/configs/mainnet/metal.toml @@ -16,6 +16,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1711563515 [genesis.l1] diff --git a/superchain/configs/mainnet/mode.toml b/superchain/configs/mainnet/mode.toml index bfc9a7cf1..9134442b8 100644 --- a/superchain/configs/mainnet/mode.toml +++ b/superchain/configs/mainnet/mode.toml @@ -16,6 +16,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1700167583 [genesis.l1] diff --git a/superchain/configs/mainnet/op.toml b/superchain/configs/mainnet/op.toml index 65da7a4dd..112329dcf 100644 --- a/superchain/configs/mainnet/op.toml +++ b/superchain/configs/mainnet/op.toml @@ -15,6 +15,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1686068903 [genesis.l1] diff --git a/superchain/configs/mainnet/orderly.toml b/superchain/configs/mainnet/orderly.toml index a295efb69..7f867052d 100644 --- a/superchain/configs/mainnet/orderly.toml +++ b/superchain/configs/mainnet/orderly.toml @@ -15,6 +15,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1696608227 [genesis.l1] diff --git a/superchain/configs/mainnet/race.toml b/superchain/configs/mainnet/race.toml index c58acf4a1..ee2fd6ea9 100644 --- a/superchain/configs/mainnet/race.toml +++ b/superchain/configs/mainnet/race.toml @@ -13,6 +13,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1720421591 [genesis.l1] diff --git a/superchain/configs/mainnet/tbn.toml b/superchain/configs/mainnet/tbn.toml index ba201207b..8edfb4304 100644 --- a/superchain/configs/mainnet/tbn.toml +++ b/superchain/configs/mainnet/tbn.toml @@ -14,6 +14,11 @@ max_sequencer_drift = 600 data_availability_type = "eth-da" gas_paying_token = "0x04E9D7e336f79Cdab911b06133D3Ca2Cd0721ce3" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1719397463 [genesis.l1] @@ -27,6 +32,11 @@ gas_paying_token = "0x04E9D7e336f79Cdab911b06133D3Ca2Cd0721ce3" overhead = "0x0000000000000000000000000000000000000000000000000000000000000000" scalar = "0x010000000000000000000000000000000000000000000000000c5fc500000558" gasLimit = 30000000 + [genesis.config] + [genesis.config.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 [addresses] SystemConfigOwner = "0x25A6E7c6f3d0fE89A656Fcf065614B74E55099fF" diff --git a/superchain/configs/mainnet/zora.toml b/superchain/configs/mainnet/zora.toml index c136f954c..1bcf47c71 100644 --- a/superchain/configs/mainnet/zora.toml +++ b/superchain/configs/mainnet/zora.toml @@ -16,6 +16,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1686693839 [genesis.l1] diff --git a/superchain/configs/sepolia-dev-0/base-devnet-0.toml b/superchain/configs/sepolia-dev-0/base-devnet-0.toml index 7eb435f4f..98dd36a7c 100644 --- a/superchain/configs/sepolia-dev-0/base-devnet-0.toml +++ b/superchain/configs/sepolia-dev-0/base-devnet-0.toml @@ -15,6 +15,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1695433056 [genesis.l1] diff --git a/superchain/configs/sepolia-dev-0/oplabs-devnet-0.toml b/superchain/configs/sepolia-dev-0/oplabs-devnet-0.toml index 25e8e5e13..aac2c2306 100644 --- a/superchain/configs/sepolia-dev-0/oplabs-devnet-0.toml +++ b/superchain/configs/sepolia-dev-0/oplabs-devnet-0.toml @@ -15,6 +15,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1706484048 [genesis.l1] diff --git a/superchain/configs/sepolia/base.toml b/superchain/configs/sepolia/base.toml index d2c333724..6b86c11ed 100644 --- a/superchain/configs/sepolia/base.toml +++ b/superchain/configs/sepolia/base.toml @@ -16,6 +16,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 10 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1695768288 [genesis.l1] diff --git a/superchain/configs/sepolia/metal.toml b/superchain/configs/sepolia/metal.toml index e75d535e8..e8df2a6d1 100644 --- a/superchain/configs/sepolia/metal.toml +++ b/superchain/configs/sepolia/metal.toml @@ -14,6 +14,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1708129620 [genesis.l1] diff --git a/superchain/configs/sepolia/mode.toml b/superchain/configs/sepolia/mode.toml index c4269a1c3..f096295e3 100644 --- a/superchain/configs/sepolia/mode.toml +++ b/superchain/configs/sepolia/mode.toml @@ -16,6 +16,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1687867932 [genesis.l1] diff --git a/superchain/configs/sepolia/op.toml b/superchain/configs/sepolia/op.toml index 17bac934b..4c13943d7 100644 --- a/superchain/configs/sepolia/op.toml +++ b/superchain/configs/sepolia/op.toml @@ -15,6 +15,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1691802540 [genesis.l1] diff --git a/superchain/configs/sepolia/race.toml b/superchain/configs/sepolia/race.toml index 26a045b50..9fd46d77e 100644 --- a/superchain/configs/sepolia/race.toml +++ b/superchain/configs/sepolia/race.toml @@ -13,6 +13,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1719646560 [genesis.l1] diff --git a/superchain/configs/sepolia/zora.toml b/superchain/configs/sepolia/zora.toml index e38a98495..e5daae856 100644 --- a/superchain/configs/sepolia/zora.toml +++ b/superchain/configs/sepolia/zora.toml @@ -16,6 +16,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1698080004 [genesis.l1] diff --git a/superchain/superchain.go b/superchain/superchain.go index c33d444fb..aa10af99c 100644 --- a/superchain/superchain.go +++ b/superchain/superchain.go @@ -31,6 +31,12 @@ type BlockID struct { Number uint64 `toml:"number"` } +type OptimismConfig struct { + EIP1559Elasticity uint64 `toml:"eip1559_elasticity" json:"eip1559Elasticity"` + EIP1559Denominator uint64 `toml:"eip1559_denominator" json:"eip1559Denominator"` + EIP1559DenominatorCanyon *uint64 `toml:"eip1559_denominator_canyon,omitempty" json:"eip1559DenominatorCanyon,omitempty"` +} + type ChainGenesis struct { L1 BlockID `toml:"l1"` L2 BlockID `toml:"l2"` @@ -104,6 +110,7 @@ type ChainConfig struct { SequencerWindowSize uint64 `toml:"seq_window_size" json:"seq_window_size"` MaxSequencerDrift uint64 `toml:"max_sequencer_drift" json:"max_sequencer_drift"` DataAvailabilityType DataAvailability `toml:"data_availability_type"` + Optimism *OptimismConfig `toml:"optimism,omitempty" json:"optimism,omitempty"` // Optional feature AltDA *AltDAConfig `toml:"alt_da,omitempty" json:"alt_da,omitempty"` diff --git a/validation/go.mod b/validation/go.mod index a384ceae4..8928b36f8 100644 --- a/validation/go.mod +++ b/validation/go.mod @@ -4,12 +4,12 @@ go 1.21 replace github.com/ethereum-optimism/superchain-registry/superchain => ../superchain -replace github.com/ethereum/go-ethereum => github.com/ethereum-optimism/op-geth v1.101407.0-rc.1.0.20240812224053-8d99ca68bb1a +replace github.com/ethereum/go-ethereum => github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240827194518-1071ac1284b8 require ( github.com/BurntSushi/toml v1.4.0 github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813 - github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240814192743-ea7e768a02a6 + github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240827194108-65ec82d9a1b2 github.com/ethereum/go-ethereum v1.14.7 github.com/stretchr/testify v1.9.0 golang.org/x/mod v0.20.0 @@ -21,11 +21,12 @@ require ( github.com/VictoriaMetrics/fastcache v1.12.2 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/bits-and-blooms/bitset v1.10.0 // indirect - github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect + github.com/btcsuite/btcd/btcec/v2 v2.3.4 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/cockroachdb/errors v1.11.3 // indirect + github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce // indirect github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect - github.com/cockroachdb/pebble v0.0.0-20231018212520-f6cde3fc2fa4 // indirect + github.com/cockroachdb/pebble v1.1.2 // indirect github.com/cockroachdb/redact v1.1.5 // indirect github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect github.com/consensys/bavard v0.1.13 // indirect @@ -38,7 +39,6 @@ require ( github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 // indirect github.com/ethereum/c-kzg-4844 v1.0.0 // indirect github.com/ethereum/go-verkle v0.1.1-0.20240306133620-7d920df305f0 // indirect - github.com/fjl/memsize v0.0.2 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect github.com/getsentry/sentry-go v0.27.0 // indirect github.com/go-ole/go-ole v1.3.0 // indirect @@ -85,11 +85,11 @@ require ( golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56 // indirect golang.org/x/net v0.27.0 // indirect golang.org/x/sync v0.8.0 // indirect - golang.org/x/sys v0.23.0 // indirect + golang.org/x/sys v0.24.0 // indirect golang.org/x/term v0.23.0 // indirect golang.org/x/text v0.17.0 // indirect golang.org/x/time v0.6.0 // indirect - google.golang.org/protobuf v1.34.1 // indirect + google.golang.org/protobuf v1.34.2 // indirect gopkg.in/natefinch/lumberjack.v2 v2.2.1 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect rsc.io/tmplfunc v0.0.3 // indirect diff --git a/validation/go.sum b/validation/go.sum index 99a8d91f1..04afaa00a 100644 --- a/validation/go.sum +++ b/validation/go.sum @@ -14,8 +14,8 @@ github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6r github.com/bits-and-blooms/bitset v1.10.0 h1:ePXTeiPEazB5+opbv5fr8umg2R/1NlzgDsyepwsSr88= github.com/bits-and-blooms/bitset v1.10.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= github.com/btcsuite/btcd v0.24.2 h1:aLmxPguqxza+4ag8R1I2nnJjSu2iFn/kqtHTIImswcY= -github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= -github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= +github.com/btcsuite/btcd/btcec/v2 v2.3.4 h1:3EJjcN70HCu/mwqlUsGK8GcNVyLVxFDlWurTXGPFfiQ= +github.com/btcsuite/btcd/btcec/v2 v2.3.4/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= github.com/btcsuite/btcd/chaincfg/chainhash v1.1.0 h1:59Kx4K6lzOW5w6nFlA0v5+lk/6sjybR934QNHSJZPTQ= github.com/btcsuite/btcd/chaincfg/chainhash v1.1.0/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= github.com/cespare/cp v0.1.0 h1:SE+dxFebS7Iik5LK0tsi1k9ZCxEaFX4AjQmoyA+1dJk= @@ -30,10 +30,12 @@ github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f h1:otljaY github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= github.com/cockroachdb/errors v1.11.3 h1:5bA+k2Y6r+oz/6Z/RFlNeVCesGARKuC6YymtcDrbC/I= github.com/cockroachdb/errors v1.11.3/go.mod h1:m4UIW4CDjx+R5cybPsNrRbreomiFqt8o1h1wUVazSd8= +github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce h1:giXvy4KSc/6g/esnpM7Geqxka4WSqI1SZc7sMJFd3y4= +github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce/go.mod h1:9/y3cnZ5GKakj/H4y9r9GTjCvAFta7KLgSHPJJYc52M= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZeQy818SGhaone5OnYfxFR/+AzdY3sf5aE= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= -github.com/cockroachdb/pebble v0.0.0-20231018212520-f6cde3fc2fa4 h1:PuHFhOUMnD62r80dN+Ik5qco2drekgsUSVdcHsvllec= -github.com/cockroachdb/pebble v0.0.0-20231018212520-f6cde3fc2fa4/go.mod h1:sEHm5NOXxyiAoKWhoFxT8xMgd/f3RA6qUqQ1BXKrh2E= +github.com/cockroachdb/pebble v1.1.2 h1:CUh2IPtR4swHlEj48Rhfzw6l/d0qA31fItcIszQVIsA= +github.com/cockroachdb/pebble v1.1.2/go.mod h1:4exszw1r40423ZsmkG/09AFEG83I0uDgfujJdbL6kYU= github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 h1:zuQyyAKVxetITBuuhv3BI9cMrmStnpT18zmgmTxunpo= @@ -59,16 +61,14 @@ github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5il github.com/decred/dcrd/crypto/blake256 v1.0.1/go.mod h1:2OfgNZ5wDpcsFmHmCK5gZTPcCXqlm2ArzUIkw9czNJo= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 h1:rpfIENRNNilwHwZeG5+P150SMrnNEcHYvcCuK6dPZSg= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= -github.com/ethereum-optimism/op-geth v1.101407.0-rc.1.0.20240812224053-8d99ca68bb1a h1:OK3wB7HbdhCneSowC1XZusHaLIVdXoRLuCWgXp5Tjuc= -github.com/ethereum-optimism/op-geth v1.101407.0-rc.1.0.20240812224053-8d99ca68bb1a/go.mod h1:9pT+bF20XwCBE7WkjfRSsCg6RN6Njdbr924DtQ3+geY= +github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240827194518-1071ac1284b8 h1:herYQxIOCZzBNAIClH0BP/+1BAXIn5bz0vRYH9bdgug= +github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240827194518-1071ac1284b8/go.mod h1:WBZxPjS4MTFLiFGEfBngof6KwdIU6zZ4t00B8zLJwDE= github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813 h1:g1eUt4iB+v+FGdO7WAI17SpVahsrC6S9HGO0ceAd8Ec= github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813/go.mod h1:LTZIluX+26O0GHlwnFdPIUX04OUqcVDdThjRDsALYUY= github.com/ethereum/c-kzg-4844 v1.0.0 h1:0X1LBXxaEtYD9xsyj9B9ctQEZIpnvVDeoBx8aHEwTNA= github.com/ethereum/c-kzg-4844 v1.0.0/go.mod h1:VewdlzQmpT5QSrVhbBuGoCdFJkpaJlO1aQputP83wc0= github.com/ethereum/go-verkle v0.1.1-0.20240306133620-7d920df305f0 h1:KrE8I4reeVvf7C1tm8elRjj4BdscTYzz/WAbYyf/JI4= github.com/ethereum/go-verkle v0.1.1-0.20240306133620-7d920df305f0/go.mod h1:D9AJLVXSyZQXJQVk8oh1EwjISE+sJTn2duYIZC0dy3w= -github.com/fjl/memsize v0.0.2 h1:27txuSD9or+NZlnOWdKUxeBzTAUkWCVh+4Gf2dWFOzA= -github.com/fjl/memsize v0.0.2/go.mod h1:VvhXpOYNQvB+uIk2RvXzuaQtkQJzzIx6lSBe1xv7hi0= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/fsnotify/fsnotify v1.5.4/go.mod h1:OVB6XrOHzAwXMpEM7uPOzcehqUV2UqJxmVXmkdnm1bU= @@ -284,8 +284,8 @@ golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.11.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.23.0 h1:YfKFowiIMvtgl1UERQoTPPToxltDeZfbj4H7dVUCwmM= -golang.org/x/sys v0.23.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.24.0 h1:Twjiwq9dn6R1fQcyiK+wQyHWfaz/BJB+YIpzU/Cv3Xg= +golang.org/x/sys v0.24.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.23.0 h1:F6D4vR+EHoL9/sWAWgAR1H2DcHr4PareCbAaCo1RpuU= @@ -316,8 +316,8 @@ google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzi google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.34.1 h1:9ddQBjfCyZPOHPUiPxpYESBLc+T8P3E+Vo4IbKZgFWg= -google.golang.org/protobuf v1.34.1/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= +google.golang.org/protobuf v1.34.2 h1:6xV6lTsCfpGD21XK49h7MhtcApnLqkfYgPcdHftf6hg= +google.golang.org/protobuf v1.34.2/go.mod h1:qYOHts0dSfpeUzUFpOMr/WGzszTmLH+DiWniOlNbLDw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= From 029f38fb8a55b625edfba2bae528cec0e52cbc8e Mon Sep 17 00:00:00 2001 From: George Knee Date: Wed, 28 Aug 2024 16:21:58 +0100 Subject: [PATCH 07/30] Remove submodule (#521) * remove submodule * add optimism-temporary to gitignore --- validation/.gitignore | 1 + validation/genesis/optimism-temporary | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) delete mode 160000 validation/genesis/optimism-temporary diff --git a/validation/.gitignore b/validation/.gitignore index a658e3534..8d22a37f7 100644 --- a/validation/.gitignore +++ b/validation/.gitignore @@ -1,2 +1,3 @@ generate-rollup-config/output-* generate-genesis/output-* +genesis/optimism-temporary diff --git a/validation/genesis/optimism-temporary b/validation/genesis/optimism-temporary deleted file mode 160000 index d80c145e0..000000000 --- a/validation/genesis/optimism-temporary +++ /dev/null @@ -1 +0,0 @@ -Subproject commit d80c145e0acf23a49c6a6588524f57e32e33b91c From 4ecea76899662a9fc3bdf606846841d750816aec Mon Sep 17 00:00:00 2001 From: refcell Date: Wed, 28 Aug 2024 11:41:51 -0400 Subject: [PATCH 08/30] feat(bindings): Remove Rust Bindings (#517) --- .circleci/config.yml | 52 - .github/CODEOWNERS | 10 - .github/workflows/release.yml | 28 - bindings/rust-bindings/.gitignore | 1 - bindings/rust-bindings/CHANGELOG.md | 19 - bindings/rust-bindings/Cargo.lock | 836 ------------- bindings/rust-bindings/Cargo.toml | 28 - bindings/rust-bindings/README.md | 63 - bindings/rust-bindings/etc/chainList.toml | 204 ---- bindings/rust-bindings/justfile | 61 - bindings/rust-bindings/src/chain_list.rs | 64 - bindings/rust-bindings/src/lib.rs | 50 - bindings/rust-bindings/src/superchain.rs | 156 --- bindings/rust-primitives/CHANGELOG.md | 25 - bindings/rust-primitives/Cargo.lock | 711 ----------- bindings/rust-primitives/Cargo.toml | 29 - bindings/rust-primitives/README.md | 71 -- bindings/rust-primitives/justfile | 61 - bindings/rust-primitives/src/addresses.rs | 86 -- bindings/rust-primitives/src/block.rs | 24 - bindings/rust-primitives/src/chain_config.rs | 112 -- bindings/rust-primitives/src/fee_params.rs | 89 -- bindings/rust-primitives/src/genesis.rs | 21 - bindings/rust-primitives/src/lib.rs | 53 - bindings/rust-primitives/src/predeploys.rs | 83 -- bindings/rust-primitives/src/rollup_config.rs | 621 ---------- bindings/rust-primitives/src/superchain.rs | 65 - bindings/rust-primitives/src/system_config.rs | 385 ------ bindings/superchain/Cargo.lock | 863 ------------- bindings/superchain/Cargo.toml | 35 - bindings/superchain/Justfile | 61 - bindings/superchain/README.md | 69 -- bindings/superchain/src/lib.rs | 18 - docs/bindings.md | 116 -- justfile | 36 +- superchain/configs/configs.toml | 1088 +++++++++++++++++ superchain/internal/codegen/main.go | 12 +- 37 files changed, 1093 insertions(+), 5213 deletions(-) delete mode 100644 .github/workflows/release.yml delete mode 100644 bindings/rust-bindings/.gitignore delete mode 100644 bindings/rust-bindings/CHANGELOG.md delete mode 100644 bindings/rust-bindings/Cargo.lock delete mode 100644 bindings/rust-bindings/Cargo.toml delete mode 100644 bindings/rust-bindings/README.md delete mode 100644 bindings/rust-bindings/etc/chainList.toml delete mode 100644 bindings/rust-bindings/justfile delete mode 100644 bindings/rust-bindings/src/chain_list.rs delete mode 100644 bindings/rust-bindings/src/lib.rs delete mode 100644 bindings/rust-bindings/src/superchain.rs delete mode 100644 bindings/rust-primitives/CHANGELOG.md delete mode 100644 bindings/rust-primitives/Cargo.lock delete mode 100644 bindings/rust-primitives/Cargo.toml delete mode 100644 bindings/rust-primitives/README.md delete mode 100644 bindings/rust-primitives/justfile delete mode 100644 bindings/rust-primitives/src/addresses.rs delete mode 100644 bindings/rust-primitives/src/block.rs delete mode 100644 bindings/rust-primitives/src/chain_config.rs delete mode 100644 bindings/rust-primitives/src/fee_params.rs delete mode 100644 bindings/rust-primitives/src/genesis.rs delete mode 100644 bindings/rust-primitives/src/lib.rs delete mode 100644 bindings/rust-primitives/src/predeploys.rs delete mode 100644 bindings/rust-primitives/src/rollup_config.rs delete mode 100644 bindings/rust-primitives/src/superchain.rs delete mode 100644 bindings/rust-primitives/src/system_config.rs delete mode 100644 bindings/superchain/Cargo.lock delete mode 100644 bindings/superchain/Cargo.toml delete mode 100644 bindings/superchain/Justfile delete mode 100644 bindings/superchain/README.md delete mode 100644 bindings/superchain/src/lib.rs delete mode 100644 docs/bindings.md create mode 100644 superchain/configs/configs.toml diff --git a/.circleci/config.yml b/.circleci/config.yml index 46b749d63..3dbe989ae 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -4,7 +4,6 @@ orbs: go: circleci/go@1.8.0 node: circleci/node@5.2.0 slack: circleci/slack@4.10.1 - rust: circleci/rust@1.6.1 commands: notify-failures-on-main: @@ -28,19 +27,6 @@ commands: echo "deb [arch=all,$(dpkg --print-architecture) signed-by=/usr/share/keyrings/prebuilt-mpr-archive-keyring.gpg] https://proget.makedeb.org prebuilt-mpr $(lsb_release -cs)" | sudo tee /etc/apt/sources.list.d/prebuilt-mpr.list sudo apt update sudo apt install just - install-nextest: - description: "Installs cargo nextest" - steps: - - run: - name: "Install nextest" - command: cargo install cargo-nextest --locked - install-rust-toolchain: - description: "Installs rust toolchain components" - steps: - - run: - name: "Install toolchain" - command: | - rustup install nightly-x86_64-unknown-linux-gnu install-foundry: description: "Installs foundry" steps: @@ -197,41 +183,6 @@ jobs: - run: name: check git tree is clean command: git diff --exit-code - cargo-tests: - docker: - - image: cimg/rust:1.79 - steps: - - checkout - - install-just - - install-nextest - - run: - name: Cargo Tests - command: just cargo-tests - - notify-failures-on-main: - channel: C03N11M0BBN # to slack channel `notify-ci-failures` - cargo-lint: - docker: - - image: cimg/rust:1.79 - steps: - - checkout - - install-just - - install-rust-toolchain - - run: - name: Cargo lints - command: just cargo-lint - - notify-failures-on-main: - channel: C03N11M0BBN # to slack channel `notify-ci-failures` - cargo-build: - docker: - - image: cimg/rust:1.79 - steps: - - checkout - - install-just - - run: - name: Cargo build - command: just cargo-build - - notify-failures-on-main: - channel: C03N11M0BBN # to slack channel `notify-ci-failures` workflows: hourly: @@ -268,6 +219,3 @@ workflows: - golang-test - golang-validate-modified - check-codegen - - cargo-tests - - cargo-lint - - cargo-build diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 72764885f..403ee10b1 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -2,16 +2,6 @@ * @ethereum-optimism/go-reviewers # Code and script ownership - -# Rust -*.rs @ethereum-optimism/rust-reviewers -Cargo.toml @ethereum-optimism/rust-reviewers -/bindings/rust-* @ethereum-optimism/rust-reviewers -/bindings/superchain @ethereum-optimism/rust-reviewers -.github/workflows/rust-checks.yml @ethereum-optimism/rust-reviewers -.github/workflows/release.yml @ethereum-optimism/rust-reviewers - -## Go *.go @ethereum-optimism/go-reviewers /go.work @ethereum-optimism/go-reviewers /.golangci.yml @ethereum-optimism/go-reviewers diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml deleted file mode 100644 index e6ae78779..000000000 --- a/.github/workflows/release.yml +++ /dev/null @@ -1,28 +0,0 @@ -name: Release Rust Crates - -on: - workflow_dispatch: - -jobs: - release-crates: - name: Release Crates - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: taiki-e/install-action@just - - uses: dtolnay/rust-toolchain@stable - - name: Install cargo release - run: cargo install cargo-release - - name: Login to cargo - run: cargo login $CARGO_REGISTRY_TOKEN - env: - CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }} - - name: Release superchain-primitives crate - run: just bindings/rust-primitives/release - continue-on-error: true - - name: Release superchain-registry crate - run: just bindings/rust-bindings/release - continue-on-error: true - - name: Release superchain crate - run: just bindings/superchain/release - continue-on-error: true diff --git a/bindings/rust-bindings/.gitignore b/bindings/rust-bindings/.gitignore deleted file mode 100644 index 2f7896d1d..000000000 --- a/bindings/rust-bindings/.gitignore +++ /dev/null @@ -1 +0,0 @@ -target/ diff --git a/bindings/rust-bindings/CHANGELOG.md b/bindings/rust-bindings/CHANGELOG.md deleted file mode 100644 index 2238fe4f0..000000000 --- a/bindings/rust-bindings/CHANGELOG.md +++ /dev/null @@ -1,19 +0,0 @@ -# Changelog -All notable changes to this project will be documented in this file. - -The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), -and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). - -## [Unreleased] - -## [0.1.1](https://github.com/ethereum-optimism/superchain-registry/compare/v0.1.0...v0.1.1) - 2024-06-25 - -### Fixed -- test release-plz ([#325](https://github.com/ethereum-optimism/superchain-registry/pull/325)) -- *(bindings)* Auto Impl Hash Trait ([#272](https://github.com/ethereum-optimism/superchain-registry/pull/272)) -- *(bindings)* Feature Flag Docs ([#269](https://github.com/ethereum-optimism/superchain-registry/pull/269)) -- *(bindings)* Split out Primitive Types ([#262](https://github.com/ethereum-optimism/superchain-registry/pull/262)) - -### Other -- *(bindings)* Version Alloy Dependencies ([#308](https://github.com/ethereum-optimism/superchain-registry/pull/308)) -- Implement new "add chain" flow ([#279](https://github.com/ethereum-optimism/superchain-registry/pull/279)) diff --git a/bindings/rust-bindings/Cargo.lock b/bindings/rust-bindings/Cargo.lock deleted file mode 100644 index 943762fb2..000000000 --- a/bindings/rust-bindings/Cargo.lock +++ /dev/null @@ -1,836 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "ahash" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" -dependencies = [ - "cfg-if", - "once_cell", - "version_check", - "zerocopy", -] - -[[package]] -name = "allocator-api2" -version = "0.2.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c6cb57a04249c6480766f7f7cef5467412af1490f8d1e243141daddada3264f" - -[[package]] -name = "alloy-consensus" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f58047cc851e58c26224521d1ecda466e3d746ebca0274cd5427aa660a88c353" -dependencies = [ - "alloy-eips", - "alloy-primitives", - "alloy-rlp", - "alloy-serde", - "serde", -] - -[[package]] -name = "alloy-eips" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d32a3e14fa0d152d00bd8daf605eb74ad397efb0f54bd7155585823dddb4401e" -dependencies = [ - "alloy-primitives", - "alloy-rlp", - "alloy-serde", - "c-kzg", - "serde", - "sha2", -] - -[[package]] -name = "alloy-genesis" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20cb76c8a3913f2466c5488f3a915e3a15d15596bdc935558c1a9be75e9ec508" -dependencies = [ - "alloy-primitives", - "alloy-serde", - "serde", -] - -[[package]] -name = "alloy-primitives" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccb3ead547f4532bc8af961649942f0b9c16ee9226e26caa3f38420651cc0bf4" -dependencies = [ - "alloy-rlp", - "bytes", - "cfg-if", - "const-hex", - "derive_more", - "hex-literal", - "itoa", - "ruint", - "serde", - "tiny-keccak", -] - -[[package]] -name = "alloy-rlp" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a43b18702501396fa9bcdeecd533bc85fac75150d308fc0f6800a01e6234a003" -dependencies = [ - "alloy-rlp-derive", - "bytes", -] - -[[package]] -name = "alloy-rlp-derive" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d83524c1f6162fcb5b0decf775498a125066c86dda6066ed609531b0e912f85a" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.72", -] - -[[package]] -name = "alloy-serde" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15c5b9057acc02aee1b8aac2b5a0729cb0f73d080082c111313e5d1f92a96630" -dependencies = [ - "alloy-primitives", - "serde", - "serde_json", -] - -[[package]] -name = "alloy-sol-macro" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b40397ddcdcc266f59f959770f601ce1280e699a91fc1862f29cef91707cd09" -dependencies = [ - "alloy-sol-macro-expander", - "alloy-sol-macro-input", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 2.0.72", -] - -[[package]] -name = "alloy-sol-macro-expander" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "867a5469d61480fea08c7333ffeca52d5b621f5ca2e44f271b117ec1fc9a0525" -dependencies = [ - "alloy-sol-macro-input", - "const-hex", - "heck", - "indexmap", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 2.0.72", - "syn-solidity", - "tiny-keccak", -] - -[[package]] -name = "alloy-sol-macro-input" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e482dc33a32b6fadbc0f599adea520bd3aaa585c141a80b404d0a3e3fa72528" -dependencies = [ - "const-hex", - "dunce", - "heck", - "proc-macro2", - "quote", - "syn 2.0.72", - "syn-solidity", -] - -[[package]] -name = "alloy-sol-types" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a91ca40fa20793ae9c3841b83e74569d1cc9af29a2f5237314fd3452d51e38c7" -dependencies = [ - "alloy-primitives", - "alloy-sol-macro", - "const-hex", -] - -[[package]] -name = "anyhow" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" - -[[package]] -name = "autocfg" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" - -[[package]] -name = "bitflags" -version = "2.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "blst" -version = "0.3.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62dc83a094a71d43eeadd254b1ec2d24cb6a0bb6cadce00df51f0db594711a32" -dependencies = [ - "cc", - "glob", - "threadpool", - "zeroize", -] - -[[package]] -name = "bytes" -version = "1.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a12916984aab3fa6e39d655a33e09c0071eb36d6ab3aea5c2d78551f1df6d952" -dependencies = [ - "serde", -] - -[[package]] -name = "c-kzg" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdf100c4cea8f207e883ff91ca886d621d8a166cb04971dfaa9bb8fd99ed95df" -dependencies = [ - "blst", - "cc", - "glob", - "hex", - "libc", - "serde", -] - -[[package]] -name = "cc" -version = "1.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2aba8f4e9906c7ce3c73463f62a7f0c65183ada1a2d47e397cc8810827f9694f" - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "const-hex" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8a24a26d37e1ffd45343323dc9fe6654ceea44c12f2fcb3d7ac29e610bc6" -dependencies = [ - "cfg-if", - "cpufeatures", - "hex", - "proptest", - "serde", -] - -[[package]] -name = "convert_case" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" - -[[package]] -name = "cpufeatures" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" -dependencies = [ - "libc", -] - -[[package]] -name = "crunchy" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "derive_more" -version = "0.99.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f33878137e4dafd7fa914ad4e259e18a4e8e532b9617a2d0150262bf53abfce" -dependencies = [ - "convert_case", - "proc-macro2", - "quote", - "rustc_version", - "syn 2.0.72", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer", - "crypto-common", -] - -[[package]] -name = "dunce" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56ce8c6da7551ec6c462cbaf3bfbc75131ebbfa1c944aeaa9dab51ca1c5f0c3b" - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "glob" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" - -[[package]] -name = "hashbrown" -version = "0.14.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" -dependencies = [ - "ahash", - "allocator-api2", - "serde", -] - -[[package]] -name = "heck" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" - -[[package]] -name = "hermit-abi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" -dependencies = [ - "serde", -] - -[[package]] -name = "hex-literal" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" - -[[package]] -name = "indexmap" -version = "2.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" -dependencies = [ - "equivalent", - "hashbrown", -] - -[[package]] -name = "itoa" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" - -[[package]] -name = "lazy_static" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" - -[[package]] -name = "libc" -version = "0.2.155" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" - -[[package]] -name = "libm" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" - -[[package]] -name = "memchr" -version = "2.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" - -[[package]] -name = "num-traits" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" -dependencies = [ - "autocfg", - "libm", -] - -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi", - "libc", -] - -[[package]] -name = "once_cell" -version = "1.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" - -[[package]] -name = "paste" -version = "1.0.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "proc-macro-error" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" -dependencies = [ - "proc-macro-error-attr", - "proc-macro2", - "quote", - "syn 1.0.109", - "version_check", -] - -[[package]] -name = "proc-macro-error-attr" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" -dependencies = [ - "proc-macro2", - "quote", - "version_check", -] - -[[package]] -name = "proc-macro2" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "proptest" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4c2511913b88df1637da85cc8d96ec8e43a3f8bb8ccb71ee1ac240d6f3df58d" -dependencies = [ - "bitflags", - "num-traits", - "rand", - "rand_chacha", - "rand_xorshift", - "unarray", -] - -[[package]] -name = "quote" -version = "1.0.36" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "rand_core", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" - -[[package]] -name = "rand_xorshift" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f" -dependencies = [ - "rand_core", -] - -[[package]] -name = "ruint" -version = "1.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c3cc4c2511671f327125da14133d0c5c5d137f006a1017a16f557bc85b16286" -dependencies = [ - "alloy-rlp", - "proptest", - "rand", - "ruint-macro", - "serde", - "valuable", - "zeroize", -] - -[[package]] -name = "ruint-macro" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48fd7bd8a6377e15ad9d42a8ec25371b94ddc67abe7c8b9127bec79bebaaae18" - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "ryu" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" - -[[package]] -name = "semver" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" - -[[package]] -name = "serde" -version = "1.0.204" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc76f558e0cbb2a839d37354c575f1dc3fdc6546b5be373ba43d95f231bf7c12" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.204" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0cd7e117be63d3c3678776753929474f3b04a43a080c744d6b0ae2a8c28e222" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.72", -] - -[[package]] -name = "serde_json" -version = "1.0.120" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e0d21c9a8cae1235ad58a00c11cb40d4b1e5c784f1ef2c537876ed6ffd8b7c5" -dependencies = [ - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.72", -] - -[[package]] -name = "serde_spanned" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" -dependencies = [ - "serde", -] - -[[package]] -name = "sha2" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "superchain-primitives" -version = "0.2.2" -dependencies = [ - "alloy-consensus", - "alloy-eips", - "alloy-genesis", - "alloy-primitives", - "alloy-sol-types", - "anyhow", - "serde", - "serde_repr", -] - -[[package]] -name = "superchain-registry" -version = "0.2.6" -dependencies = [ - "alloy-primitives", - "hashbrown", - "lazy_static", - "serde", - "superchain-primitives", - "toml", -] - -[[package]] -name = "syn" -version = "1.0.109" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" -dependencies = [ - "proc-macro2", - "unicode-ident", -] - -[[package]] -name = "syn" -version = "2.0.72" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "syn-solidity" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c837dc8852cb7074e46b444afb81783140dab12c58867b49fb3898fbafedf7ea" -dependencies = [ - "paste", - "proc-macro2", - "quote", - "syn 2.0.72", -] - -[[package]] -name = "threadpool" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d050e60b33d41c19108b32cea32164033a9013fe3b46cbd4457559bfbf77afaa" -dependencies = [ - "num_cpus", -] - -[[package]] -name = "tiny-keccak" -version = "2.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c9d3793400a45f954c52e73d068316d76b6f4e36977e3fcebb13a2721e80237" -dependencies = [ - "crunchy", -] - -[[package]] -name = "toml" -version = "0.8.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac2caab0bf757388c6c0ae23b3293fdb463fee59434529014f85e3263b995c28" -dependencies = [ - "serde", - "serde_spanned", - "toml_datetime", - "toml_edit", -] - -[[package]] -name = "toml_datetime" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_edit" -version = "0.22.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "278f3d518e152219c994ce877758516bca5e118eaed6996192a774fb9fbf0788" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "winnow", -] - -[[package]] -name = "typenum" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" - -[[package]] -name = "unarray" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" - -[[package]] -name = "unicode-ident" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" - -[[package]] -name = "valuable" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "winnow" -version = "0.6.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "557404e450152cd6795bb558bca69e43c585055f4606e3bcae5894fc6dac9ba0" -dependencies = [ - "memchr", -] - -[[package]] -name = "zerocopy" -version = "0.7.35" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0" -dependencies = [ - "zerocopy-derive", -] - -[[package]] -name = "zerocopy-derive" -version = "0.7.35" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.72", -] - -[[package]] -name = "zeroize" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.72", -] diff --git a/bindings/rust-bindings/Cargo.toml b/bindings/rust-bindings/Cargo.toml deleted file mode 100644 index 6b060c677..000000000 --- a/bindings/rust-bindings/Cargo.toml +++ /dev/null @@ -1,28 +0,0 @@ -[package] -name = "superchain-registry" -description = "Bindings for the Superchain Registry" -version = "0.2.6" -edition = "2021" -license = "MIT" -authors = ["OP Contributors"] -repository = "https://github.com/ethereum-optimism/superchain-registry" -homepage = "https://github.com/ethereum-optimism/superchain-registry/bindings/rust" - -[dependencies] -# External Dependencies -lazy_static = "1.4.0" -hashbrown = { version = "0.14.3", features = ["serde"] } - -# Workspace Dependencies -superchain-primitives = { path = "../rust-primitives", version = "0.2.2", default-features = false, features = ["serde"] } - -# Serialization -serde = { version = "1.0.203", default-features = false, features = ["derive", "alloc"] } -toml = { version = "0.8.14" } - -[dev-dependencies] -alloy-primitives = { version = "0.7.1", default-features = false } - -[features] -default = ["std"] -std = ["superchain-primitives/std"] diff --git a/bindings/rust-bindings/README.md b/bindings/rust-bindings/README.md deleted file mode 100644 index 49ff8bf79..000000000 --- a/bindings/rust-bindings/README.md +++ /dev/null @@ -1,63 +0,0 @@ -# `superchain-registry` - -This crate provides Rust bindings for the [Superchain Registry][sr]. - -[`serde`][s] is a required dependency unlike [`superchain-primitives`][sp]. - -[`superchain-registry`][scr] is an optionally `no_std` crate, by disabling -the `std` feature flag. By default, `std` is enabled, providing standard -library support. - -## Usage - -Add the following to your `Cargo.toml`. - -```toml -[dependencies] -superchain-registry = "0.2" -``` - -To disable `std` and make `superchain-registry` `no_std` compatible, -simply toggle `default-features` off. - -```toml -[dependencies] -superchain-registry = { version = "0.2", default-features = false } -``` - -## Example - -[`superchain-registry`][scr] exposes lazily defined mappings from chain id -to chain configurations. Below demonstrates getting the `RollupConfig` for -OP Mainnet (Chain ID `10`). - -```rust -use superchain_registry::ROLLUP_CONFIGS; - -let op_chain_id = 10; -let op_rollup_config = ROLLUP_CONFIGS.get(&op_chain_id); -println!("OP Mainnet Rollup Config: {:?}", op_rollup_config); -``` - -A mapping from chain id to `ChainConfig` is also available. - -```rust -use superchain_registry::OPCHAINS; - -let op_chain_id = 10; -let op_chain_config = OPCHAINS.get(&op_chain_id); -println!("OP Mainnet Chain Config: {:?}", op_chain_config); -``` - -## Feature Flags - -- `std`: Uses the standard library to pull in environment variables. - - - - -[sp]: ../rust-primitives - -[s]: https://crates.io/crates/serde -[sr]: https://github.com/ethereum-optimism/superchain-registry -[scr]: https://crates.io/crates/superchain-registry diff --git a/bindings/rust-bindings/etc/chainList.toml b/bindings/rust-bindings/etc/chainList.toml deleted file mode 100644 index b347e0b11..000000000 --- a/bindings/rust-bindings/etc/chainList.toml +++ /dev/null @@ -1,204 +0,0 @@ -[[chains]] - name = "OP Mainnet" - identifier = "mainnet/op" - chain_id = 10 - rpc = ["https://mainnet.optimism.io"] - explorers = ["https://explorer.optimism.io"] - superchain_level = 1 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "mainnet" - -[[chains]] - name = "Base" - identifier = "mainnet/base" - chain_id = 8453 - rpc = ["https://mainnet.base.org"] - explorers = ["https://explorer.base.org"] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "mainnet" - -[[chains]] - name = "Lyra Chain" - identifier = "mainnet/lyra" - chain_id = 957 - rpc = ["https://rpc.lyra.finance"] - explorers = ["https://explorer.lyra.finance"] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "mainnet" - -[[chains]] - name = "Metal L2" - identifier = "mainnet/metal" - chain_id = 1750 - rpc = ["https://rpc.metall2.com"] - explorers = ["https://explorer.metall2.com"] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "mainnet" - -[[chains]] - name = "Mode" - identifier = "mainnet/mode" - chain_id = 34443 - rpc = ["https://mainnet.mode.network"] - explorers = ["https://explorer.mode.network"] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "mainnet" - -[[chains]] - name = "Orderly Mainnet" - identifier = "mainnet/orderly" - chain_id = 291 - rpc = ["https://rpc.orderly.network"] - explorers = ["https://explorer.orderly.network"] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "mainnet" - -[[chains]] - name = "RACE Mainnet" - identifier = "mainnet/race" - chain_id = 6805 - rpc = ["https://racemainnet.io"] - explorers = ["https://racescan.io/"] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "mainnet" - -[[chains]] - name = "Binary Mainnet" - identifier = "mainnet/tbn" - chain_id = 624 - rpc = ["https://rpc.zero.thebinaryholdings.com"] - explorers = ["https://explorer.thebinaryholdings.com/"] - superchain_level = 0 - data_availability_type = "eth-da" - gas_paying_token = "0x04E9D7e336f79Cdab911b06133D3Ca2Cd0721ce3" - [chains.parent] - type = "L2" - chain = "mainnet" - -[[chains]] - name = "Zora" - identifier = "mainnet/zora" - chain_id = 7777777 - rpc = ["https://rpc.zora.energy"] - explorers = ["https://explorer.zora.energy"] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "mainnet" - -[[chains]] - name = "OP Sepolia Testnet" - identifier = "sepolia/op" - chain_id = 11155420 - rpc = ["https://sepolia.optimism.io"] - explorers = ["https://sepolia-optimistic.etherscan.io"] - superchain_level = 1 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "sepolia" - -[[chains]] - name = "Base Sepolia Testnet" - identifier = "sepolia/base" - chain_id = 84532 - rpc = ["https://sepolia.base.org"] - explorers = ["https://sepolia-explorer.base.org"] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "sepolia" - -[[chains]] - name = "Metal L2 Testnet" - identifier = "sepolia/metal" - chain_id = 1740 - rpc = ["https://testnet.rpc.metall2.com"] - explorers = ["https://testnet.explorer.metall2.com"] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "sepolia" - -[[chains]] - name = "Mode Testnet" - identifier = "sepolia/mode" - chain_id = 919 - rpc = ["https://sepolia.mode.network"] - explorers = ["https://sepolia.explorer.mode.network"] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "sepolia" - -[[chains]] - name = "RACE Testnet" - identifier = "sepolia/race" - chain_id = 6806 - rpc = ["https://racetestnet.io"] - explorers = ["https://testnet.racescan.io/"] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "sepolia" - -[[chains]] - name = "Zora Sepolia Testnet" - identifier = "sepolia/zora" - chain_id = 999999999 - rpc = ["https://sepolia.rpc.zora.energy"] - explorers = ["https://sepolia.explorer.zora.energy"] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "sepolia" - -[[chains]] - name = "Base devnet 0" - identifier = "sepolia-dev-0/base-devnet-0" - chain_id = 11763072 - rpc = [""] - explorers = [""] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "sepolia-dev-0" - -[[chains]] - name = "OP Labs Sepolia devnet 0" - identifier = "sepolia-dev-0/oplabs-devnet-0" - chain_id = 11155421 - rpc = [""] - explorers = [""] - superchain_level = 0 - data_availability_type = "eth-da" - [chains.parent] - type = "L2" - chain = "sepolia-dev-0" diff --git a/bindings/rust-bindings/justfile b/bindings/rust-bindings/justfile deleted file mode 100644 index bd92ae78f..000000000 --- a/bindings/rust-bindings/justfile +++ /dev/null @@ -1,61 +0,0 @@ -set positional-arguments -alias t := tests -alias l := lint -alias f := fmt -alias b := build - -# default recipe to display help information -default: - @just --list - -# Runs everything needed for ci -ci: fmt lint tests - -# Run all tests -tests: test test-features test-docs - -# Formats -fmt: fmt-fix fmt-check - -# Lint the workspace for all available targets -lint: lint-source lint-source-features lint-docs - -# Build for the native target -build *args='': - cargo build --workspace --all $@ - -# Fixes the formatting -fmt-fix: - cargo +nightly fmt --all - -# Check the formatting -fmt-check: - cargo +nightly fmt --all -- --check - -# Lint the workspace -lint-source: fmt-check - cargo +nightly clippy --all --all-targets -- -D warnings - -# Lint the workspace -lint-source-features: fmt-check - cargo +nightly clippy --all --all-features --all-targets -- -D warnings - -# Lint the Rust documentation -lint-docs: - RUSTDOCFLAGS="-D warnings" cargo doc --all --no-deps --document-private-items - -# Test without features -test *args='': - cargo nextest run --all $@ - -# Test for the native target with all features -test-features *args='': - cargo nextest run --all --all-features $@ - -# Test the Rust documentation -test-docs: - cargo test --doc --all --locked - -# Release the crate -release: - cargo release publish --execute --no-confirm diff --git a/bindings/rust-bindings/src/chain_list.rs b/bindings/rust-bindings/src/chain_list.rs deleted file mode 100644 index 9e5160705..000000000 --- a/bindings/rust-bindings/src/chain_list.rs +++ /dev/null @@ -1,64 +0,0 @@ -//! List of OP Stack chains. - -use alloc::{string::String, vec::Vec}; - -/// List of Chains. -#[derive(Debug, Clone, Default, Hash, Eq, PartialEq, serde::Serialize, serde::Deserialize)] -pub struct ChainList { - /// List of Chains. - pub chains: Vec, -} - -/// A Chain Definition. -#[derive(Debug, Clone, Default, Hash, Eq, PartialEq, serde::Serialize, serde::Deserialize)] -pub struct Chain { - /// The name of the chain. - pub name: String, - /// Chain identifier. - pub identifier: String, - /// Chain ID. - pub chain_id: u64, - /// List of RPC Endpoints. - pub rpc: Vec, - /// List of Explorer Endpoints. - pub explorers: Vec, - /// The Superchain Level. - pub superchain_level: u64, - /// The Superchain Parent. - pub parent: SuperchainParent, -} - -/// A Chain Parent -#[derive(Debug, Clone, Default, Hash, Eq, PartialEq, serde::Serialize, serde::Deserialize)] -#[serde(rename_all = "camelCase")] -pub struct SuperchainParent { - /// The parent type. - pub r#type: String, - /// The chain identifier. - pub chain: String, -} - -impl SuperchainParent { - /// Returns the chain id for the parent. - pub fn chain_id(&self) -> u64 { - match self.chain.as_ref() { - "mainnet" => 1, - "sepolia" => 11155111, - "sepolia-dev-0" => 11155421, - _ => 10, - } - } -} - -#[cfg(test)] -pub mod tests { - use super::*; - - #[test] - fn read_chain_list_file() { - let chain_list = include_str!("../../../chainList.toml"); - let chains: ChainList = toml::from_str(chain_list).unwrap(); - let base_chain = chains.chains.iter().find(|c| c.name == "Base").unwrap(); - assert_eq!(base_chain.chain_id, 8453); - } -} diff --git a/bindings/rust-bindings/src/lib.rs b/bindings/rust-bindings/src/lib.rs deleted file mode 100644 index fb342a9c2..000000000 --- a/bindings/rust-bindings/src/lib.rs +++ /dev/null @@ -1,50 +0,0 @@ -#![doc = include_str!("../README.md")] -#![warn(missing_debug_implementations, missing_docs, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] -#![cfg_attr(not(test), warn(unused_crate_dependencies))] -#![cfg_attr(not(feature = "std"), no_std)] - -extern crate alloc; - -use alloc::vec::Vec; -pub use hashbrown::HashMap; -pub use superchain_primitives::*; - -pub mod chain_list; -pub use chain_list::{Chain, ChainList}; - -pub mod superchain; -pub use superchain::Registry; - -lazy_static::lazy_static! { - /// Private initializer that loads the superchain configurations. - static ref _INIT: Registry = Registry::from_chain_list(); - - /// Chain configurations exported from the registry - pub static ref CHAINS: Vec = _INIT.chains.clone(); - - /// OP Chain configurations exported from the registry - pub static ref OPCHAINS: HashMap = _INIT.op_chains.clone(); - - /// Rollup configurations exported from the registry - pub static ref ROLLUP_CONFIGS: HashMap = _INIT.rollup_configs.clone(); -} - -#[cfg(test)] -mod tests { - #[test] - fn test_hardcoded_rollup_configs() { - let test_cases = vec![ - (10, superchain_primitives::OP_MAINNET_CONFIG), - (8453, superchain_primitives::BASE_MAINNET_CONFIG), - (11155420, superchain_primitives::OP_SEPOLIA_CONFIG), - (84532, superchain_primitives::BASE_SEPOLIA_CONFIG), - ]; - - for (chain_id, expected) in test_cases { - let derived = super::ROLLUP_CONFIGS.get(&chain_id).unwrap(); - assert_eq!(expected, *derived); - } - } -} diff --git a/bindings/rust-bindings/src/superchain.rs b/bindings/rust-bindings/src/superchain.rs deleted file mode 100644 index 6ac1b73a3..000000000 --- a/bindings/rust-bindings/src/superchain.rs +++ /dev/null @@ -1,156 +0,0 @@ -//! Contains the full superchain data. - -use super::{Chain, ChainConfig, ChainList, HashMap, RollupConfig, Superchain}; -use alloc::vec::Vec; - -/// A list of Hydrated Superchain Configs. -#[derive(Debug, Clone, Default, Eq, PartialEq, serde::Serialize, serde::Deserialize)] -#[serde(rename_all = "camelCase")] -pub struct Superchains { - /// A list of superchain configs. - pub superchains: Vec, -} - -/// The registry containing all the superchain configurations. -#[derive(Debug, Clone, Default, Eq, PartialEq, serde::Serialize, serde::Deserialize)] -#[serde(rename_all = "camelCase")] -pub struct Registry { - /// The list of chains. - pub chains: Vec, - /// Map of chain IDs to their chain configuration. - pub op_chains: HashMap, - /// Map of chain IDs to their rollup configurations. - pub rollup_configs: HashMap, -} - -impl Registry { - /// Read the chain list. - pub fn read_chain_list() -> ChainList { - let chain_list = include_str!("../etc/chainList.toml"); - toml::from_str(chain_list).expect("Failed to read chain list") - } - - /// Read superchain configs. - pub fn read_superchain_configs() -> Superchains { - let superchain_configs = include_str!("../etc/configs.toml"); - toml::from_str(superchain_configs).expect("Failed to read superchain configs") - } - - /// Initialize the superchain configurations from the chain list. - pub fn from_chain_list() -> Self { - let chains = Self::read_chain_list().chains; - let superchains = Self::read_superchain_configs(); - let mut op_chains = HashMap::new(); - let mut rollup_configs = HashMap::new(); - - for superchain in superchains.superchains.into_iter() { - for mut chain_config in superchain.chains.into_iter() { - chain_config.l1_chain_id = superchain.config.l1.chain_id; - if let Some(a) = &mut chain_config.addresses { - a.zero_proof_addresses(); - } - let mut rollup = superchain_primitives::load_op_stack_rollup_config(&chain_config); - rollup.protocol_versions_address = superchain - .config - .protocol_versions_addr - .expect("Missing protocol versions address"); - rollup.superchain_config_address = superchain.config.superchain_config_addr; - rollup_configs.insert(chain_config.chain_id, rollup); - op_chains.insert(chain_config.chain_id, chain_config); - } - } - - Self { - chains, - op_chains, - rollup_configs, - } - } -} - -#[cfg(test)] -mod tests { - use super::*; - use alloy_primitives::{address, b256, uint}; - use superchain_primitives::{ - AddressList, BlockID, ChainGenesis, HardForkConfiguration, SuperchainLevel, SystemConfig, - }; - - #[test] - fn test_read_chain_configs() { - let superchains = Registry::from_chain_list(); - assert!(superchains.chains.len() > 1); - let base_config = ChainConfig { - name: String::from("Base"), - chain_id: 8453, - l1_chain_id: 1, - superchain_time: Some(0), - public_rpc: String::from("https://mainnet.base.org"), - sequencer_rpc: String::from("https://mainnet-sequencer.base.org"), - explorer: String::from("https://explorer.base.org"), - superchain_level: SuperchainLevel::Frontier, - batch_inbox_addr: address!("ff00000000000000000000000000000000008453"), - genesis: ChainGenesis { - l1: BlockID { - number: 17481768, - hash: b256!("5c13d307623a926cd31415036c8b7fa14572f9dac64528e857a470511fc30771"), - }, - l2: BlockID { - number: 0, - hash: b256!("f712aa9241cc24369b143cf6dce85f0902a9731e70d66818a3a5845b296c73dd"), - }, - l2_time: 1686789347, - extra_data: None, - system_config: Some(SystemConfig { - batcher_address: address!("5050F69a9786F081509234F1a7F4684b5E5b76C9"), - overhead: uint!(0xbc_U256), - scalar: uint!(0xa6fe0_U256), - gas_limit: 30000000_u64, - ..Default::default() - }), - }, - superchain: String::from(""), - chain: String::from(""), - hardfork_configuration: HardForkConfiguration { - canyon_time: Some(1704992401), - delta_time: Some(1708560000), - ecotone_time: Some(1710374401), - fjord_time: Some(1720627201), - granite_time: Some(1726070401), - holocene_time: None, - }, - alt_da: None, - addresses: Some(AddressList { - address_manager: address!("8EfB6B5c4767B09Dc9AA6Af4eAA89F749522BaE2"), - l1_cross_domain_messenger_proxy: address!( - "866E82a600A1414e583f7F13623F1aC5d58b0Afa" - ), - l1_erc721_bridge_proxy: address!("608d94945A64503E642E6370Ec598e519a2C1E53"), - l1_standard_bridge_proxy: address!("3154Cf16ccdb4C6d922629664174b904d80F2C35"), - l2_output_oracle_proxy: Some(address!("56315b90c40730925ec5485cf004d835058518A0")), - optimism_mintable_erc20_factory_proxy: address!( - "05cc379EBD9B30BbA19C6fA282AB29218EC61D84" - ), - optimism_portal_proxy: address!("49048044D57e1C92A77f79988d21Fa8fAF74E97e"), - system_config_proxy: address!("73a79Fab69143498Ed3712e519A88a918e1f4072"), - system_config_owner: address!("14536667Cd30e52C0b458BaACcB9faDA7046E056"), - proxy_admin: address!("0475cBCAebd9CE8AfA5025828d5b98DFb67E059E"), - proxy_admin_owner: address!("7bB41C3008B3f03FE483B28b8DB90e19Cf07595c"), - challenger: Some(address!("6F8C5bA3F59ea3E76300E3BEcDC231D656017824")), - guardian: address!("09f7150d8c019bef34450d6920f6b3608cefdaf2"), - ..Default::default() - }), - }; - assert_eq!(*superchains.op_chains.get(&8453).unwrap(), base_config); - } - - #[test] - fn test_read_rollup_configs() { - use superchain_primitives::OP_MAINNET_CONFIG; - let superchains = Registry::from_chain_list(); - assert_eq!( - *superchains.rollup_configs.get(&10).unwrap(), - OP_MAINNET_CONFIG - ); - } -} diff --git a/bindings/rust-primitives/CHANGELOG.md b/bindings/rust-primitives/CHANGELOG.md deleted file mode 100644 index c21fd5785..000000000 --- a/bindings/rust-primitives/CHANGELOG.md +++ /dev/null @@ -1,25 +0,0 @@ -# Changelog -All notable changes to this project will be documented in this file. - -The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), -and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). - -## [Unreleased] - -## [0.1.1](https://github.com/ethereum-optimism/superchain-registry/compare/v0.1.0...v0.1.1) - 2024-06-26 - -### Added -- *(bindings)* Adds OP Stack Predeploys to Superchain Primitives ([#310](https://github.com/ethereum-optimism/superchain-registry/pull/310)) - -### Fixed -- *(bindings)* Base sepolia elasticity multiplier ([#311](https://github.com/ethereum-optimism/superchain-registry/pull/311)) -- *(bindings)* Auto Impl Hash Trait ([#272](https://github.com/ethereum-optimism/superchain-registry/pull/272)) -- *(bindings)* Split out Primitive Types ([#262](https://github.com/ethereum-optimism/superchain-registry/pull/262)) - -### Other -- test release plz flow ([#322](https://github.com/ethereum-optimism/superchain-registry/pull/322)) -- test release plz workflow ([#318](https://github.com/ethereum-optimism/superchain-registry/pull/318)) -- small fix to test release plz ([#314](https://github.com/ethereum-optimism/superchain-registry/pull/314)) -- *(bindings)* Version Alloy Dependencies ([#308](https://github.com/ethereum-optimism/superchain-registry/pull/308)) -- Basic RollupConfig Map ([#307](https://github.com/ethereum-optimism/superchain-registry/pull/307)) -- *(fjord)* fjord + tests ([#296](https://github.com/ethereum-optimism/superchain-registry/pull/296)) diff --git a/bindings/rust-primitives/Cargo.lock b/bindings/rust-primitives/Cargo.lock deleted file mode 100644 index 007187155..000000000 --- a/bindings/rust-primitives/Cargo.lock +++ /dev/null @@ -1,711 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "alloy-consensus" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f58047cc851e58c26224521d1ecda466e3d746ebca0274cd5427aa660a88c353" -dependencies = [ - "alloy-eips", - "alloy-primitives", - "alloy-rlp", - "alloy-serde", - "serde", -] - -[[package]] -name = "alloy-eips" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d32a3e14fa0d152d00bd8daf605eb74ad397efb0f54bd7155585823dddb4401e" -dependencies = [ - "alloy-primitives", - "alloy-rlp", - "alloy-serde", - "c-kzg", - "serde", - "sha2", -] - -[[package]] -name = "alloy-genesis" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20cb76c8a3913f2466c5488f3a915e3a15d15596bdc935558c1a9be75e9ec508" -dependencies = [ - "alloy-primitives", - "alloy-serde", - "serde", -] - -[[package]] -name = "alloy-primitives" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccb3ead547f4532bc8af961649942f0b9c16ee9226e26caa3f38420651cc0bf4" -dependencies = [ - "alloy-rlp", - "bytes", - "cfg-if", - "const-hex", - "derive_more", - "hex-literal", - "itoa", - "ruint", - "serde", - "tiny-keccak", -] - -[[package]] -name = "alloy-rlp" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a43b18702501396fa9bcdeecd533bc85fac75150d308fc0f6800a01e6234a003" -dependencies = [ - "alloy-rlp-derive", - "bytes", -] - -[[package]] -name = "alloy-rlp-derive" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d83524c1f6162fcb5b0decf775498a125066c86dda6066ed609531b0e912f85a" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.72", -] - -[[package]] -name = "alloy-serde" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15c5b9057acc02aee1b8aac2b5a0729cb0f73d080082c111313e5d1f92a96630" -dependencies = [ - "alloy-primitives", - "serde", - "serde_json", -] - -[[package]] -name = "alloy-sol-macro" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b40397ddcdcc266f59f959770f601ce1280e699a91fc1862f29cef91707cd09" -dependencies = [ - "alloy-sol-macro-expander", - "alloy-sol-macro-input", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 2.0.72", -] - -[[package]] -name = "alloy-sol-macro-expander" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "867a5469d61480fea08c7333ffeca52d5b621f5ca2e44f271b117ec1fc9a0525" -dependencies = [ - "alloy-sol-macro-input", - "const-hex", - "heck", - "indexmap", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 2.0.72", - "syn-solidity", - "tiny-keccak", -] - -[[package]] -name = "alloy-sol-macro-input" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e482dc33a32b6fadbc0f599adea520bd3aaa585c141a80b404d0a3e3fa72528" -dependencies = [ - "const-hex", - "dunce", - "heck", - "proc-macro2", - "quote", - "syn 2.0.72", - "syn-solidity", -] - -[[package]] -name = "alloy-sol-types" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a91ca40fa20793ae9c3841b83e74569d1cc9af29a2f5237314fd3452d51e38c7" -dependencies = [ - "alloy-primitives", - "alloy-sol-macro", - "const-hex", -] - -[[package]] -name = "anyhow" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" - -[[package]] -name = "autocfg" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" - -[[package]] -name = "bitflags" -version = "2.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "blst" -version = "0.3.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62dc83a094a71d43eeadd254b1ec2d24cb6a0bb6cadce00df51f0db594711a32" -dependencies = [ - "cc", - "glob", - "threadpool", - "zeroize", -] - -[[package]] -name = "bytes" -version = "1.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a12916984aab3fa6e39d655a33e09c0071eb36d6ab3aea5c2d78551f1df6d952" -dependencies = [ - "serde", -] - -[[package]] -name = "c-kzg" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdf100c4cea8f207e883ff91ca886d621d8a166cb04971dfaa9bb8fd99ed95df" -dependencies = [ - "blst", - "cc", - "glob", - "hex", - "libc", - "serde", -] - -[[package]] -name = "cc" -version = "1.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2aba8f4e9906c7ce3c73463f62a7f0c65183ada1a2d47e397cc8810827f9694f" - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "const-hex" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8a24a26d37e1ffd45343323dc9fe6654ceea44c12f2fcb3d7ac29e610bc6" -dependencies = [ - "cfg-if", - "cpufeatures", - "hex", - "proptest", - "serde", -] - -[[package]] -name = "convert_case" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" - -[[package]] -name = "cpufeatures" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" -dependencies = [ - "libc", -] - -[[package]] -name = "crunchy" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "derive_more" -version = "0.99.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f33878137e4dafd7fa914ad4e259e18a4e8e532b9617a2d0150262bf53abfce" -dependencies = [ - "convert_case", - "proc-macro2", - "quote", - "rustc_version", - "syn 2.0.72", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer", - "crypto-common", -] - -[[package]] -name = "dunce" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56ce8c6da7551ec6c462cbaf3bfbc75131ebbfa1c944aeaa9dab51ca1c5f0c3b" - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "glob" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" - -[[package]] -name = "hashbrown" -version = "0.14.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" - -[[package]] -name = "heck" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" - -[[package]] -name = "hermit-abi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" -dependencies = [ - "serde", -] - -[[package]] -name = "hex-literal" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" - -[[package]] -name = "indexmap" -version = "2.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" -dependencies = [ - "equivalent", - "hashbrown", -] - -[[package]] -name = "itoa" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" - -[[package]] -name = "libc" -version = "0.2.155" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" - -[[package]] -name = "libm" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" - -[[package]] -name = "num-traits" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" -dependencies = [ - "autocfg", - "libm", -] - -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi", - "libc", -] - -[[package]] -name = "paste" -version = "1.0.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "proc-macro-error" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" -dependencies = [ - "proc-macro-error-attr", - "proc-macro2", - "quote", - "syn 1.0.109", - "version_check", -] - -[[package]] -name = "proc-macro-error-attr" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" -dependencies = [ - "proc-macro2", - "quote", - "version_check", -] - -[[package]] -name = "proc-macro2" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "proptest" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4c2511913b88df1637da85cc8d96ec8e43a3f8bb8ccb71ee1ac240d6f3df58d" -dependencies = [ - "bitflags", - "num-traits", - "rand", - "rand_chacha", - "rand_xorshift", - "unarray", -] - -[[package]] -name = "quote" -version = "1.0.36" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "rand_core", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" - -[[package]] -name = "rand_xorshift" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f" -dependencies = [ - "rand_core", -] - -[[package]] -name = "ruint" -version = "1.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c3cc4c2511671f327125da14133d0c5c5d137f006a1017a16f557bc85b16286" -dependencies = [ - "alloy-rlp", - "proptest", - "rand", - "ruint-macro", - "serde", - "valuable", - "zeroize", -] - -[[package]] -name = "ruint-macro" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48fd7bd8a6377e15ad9d42a8ec25371b94ddc67abe7c8b9127bec79bebaaae18" - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "ryu" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" - -[[package]] -name = "semver" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" - -[[package]] -name = "serde" -version = "1.0.204" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc76f558e0cbb2a839d37354c575f1dc3fdc6546b5be373ba43d95f231bf7c12" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.204" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0cd7e117be63d3c3678776753929474f3b04a43a080c744d6b0ae2a8c28e222" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.72", -] - -[[package]] -name = "serde_json" -version = "1.0.120" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e0d21c9a8cae1235ad58a00c11cb40d4b1e5c784f1ef2c537876ed6ffd8b7c5" -dependencies = [ - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.72", -] - -[[package]] -name = "sha2" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "superchain-primitives" -version = "0.2.2" -dependencies = [ - "alloy-consensus", - "alloy-eips", - "alloy-genesis", - "alloy-primitives", - "alloy-sol-types", - "anyhow", - "serde", - "serde_repr", -] - -[[package]] -name = "syn" -version = "1.0.109" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" -dependencies = [ - "proc-macro2", - "unicode-ident", -] - -[[package]] -name = "syn" -version = "2.0.72" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "syn-solidity" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c837dc8852cb7074e46b444afb81783140dab12c58867b49fb3898fbafedf7ea" -dependencies = [ - "paste", - "proc-macro2", - "quote", - "syn 2.0.72", -] - -[[package]] -name = "threadpool" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d050e60b33d41c19108b32cea32164033a9013fe3b46cbd4457559bfbf77afaa" -dependencies = [ - "num_cpus", -] - -[[package]] -name = "tiny-keccak" -version = "2.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c9d3793400a45f954c52e73d068316d76b6f4e36977e3fcebb13a2721e80237" -dependencies = [ - "crunchy", -] - -[[package]] -name = "typenum" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" - -[[package]] -name = "unarray" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" - -[[package]] -name = "unicode-ident" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" - -[[package]] -name = "valuable" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "zeroize" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.72", -] diff --git a/bindings/rust-primitives/Cargo.toml b/bindings/rust-primitives/Cargo.toml deleted file mode 100644 index dd1e3c4f0..000000000 --- a/bindings/rust-primitives/Cargo.toml +++ /dev/null @@ -1,29 +0,0 @@ -[package] -name = "superchain-primitives" -description = "Primitive Types for the Superchain Registry" -version = "0.2.2" -edition = "2021" -license = "MIT" -authors = ["OP Contributors"] -repository = "https://github.com/ethereum-optimism/superchain-registry" -homepage = "https://github.com/ethereum-optimism/superchain-registry/bindings/rust-primitives" - -[dependencies] -# External Dependencies -anyhow = { version = "1.0.86", default-features = false } - -# Alloy Types -alloy-sol-types = { version = "0.7.6", default-features = false } -alloy-primitives = { version = "0.7.1", default-features = false } -alloy-genesis = { version = "0.2", default-features = false } -alloy-consensus = { version = "0.2", default-features = false } -alloy-eips = { version = "0.2", default-features = false } - -# `serde` feature flag dependencies -serde = { version = "1.0.203", default-features = false, features = ["derive", "alloc"], optional = true } -serde_repr = { version = "0.1", optional = true } - -[features] -default = ["std", "serde"] -std = [] -serde = ["dep:serde", "dep:serde_repr", "alloy-eips/serde", "alloy-consensus/serde", "alloy-primitives/serde"] diff --git a/bindings/rust-primitives/README.md b/bindings/rust-primitives/README.md deleted file mode 100644 index 02da60737..000000000 --- a/bindings/rust-primitives/README.md +++ /dev/null @@ -1,71 +0,0 @@ -# `superchain-primitives` - -A set of primitive types for the superchain. -These types mirror the golang types defined by the `superchain-registry`. - -[`superchain-primitives`][sp] is a `no_std` [crate][rpc] with optional type support for -[`serde`][serde] serialization and deserialization providing a `serde` feature flag. - -Standard library support is available by enabling the `std` feature flag on the -[`superchain-primitives`][sp] dependency. - -By default, both the `std` and `serde` feature flags **are** enabled. - -## Usage - -Add the following to your `Cargo.toml`. - -```toml -[dependencies] -superchain-primitives = "0.2" -``` - -To disable default feature flags, disable the `default-features` field like so. - -```toml -superchain-primitives = { version = "0.2", default-features = false } -``` - -Features can then be enabled individually. - -```toml -superchain-primitives = { version = "0.2", default-features = false, features = [ "std" ] } -``` - -## Example - -Below uses statically defined rollup configs for common chain ids. - -```rust -use superchain_primitives::rollup_config_from_chain_id; - -let op_mainnet_rollup_config = rollup_config_from_chain_id(10).unwrap(); -println!("OP Mainnet Rollup Config:\n{op_mainnet_rollup_config:?}"); -``` - -To inherit rollup configs defined by the `superchain-registry`, -use the `superchain-registry` crate defined in [rust-bindings][rb]. -Note, `serde` is required. - -## Feature Flags - -- `serde`: Implements serialization and deserialization for types. -- `std`: Uses standard library types. - -## Hardcoded Rollup Configs - -- [`OP_MAINNET_CONFIG`][rcfg]: OP Mainnet (Chain ID: `10`) -- [`OP_SEPOLIA_CONFIG`][rcfg]: OP Sepolia (Chain ID: `11155420`) -- [`BASE_MAINNET_CONFIG`][rcfg]: Base Mainnet (Chain ID: `8453`) -- [`BASE_SEPOLIA_CONFIG`][rcfg]: Base Sepolia (Chain ID: `84532`) - - - -[rb]: ../rust-bindings -[rpc]: ./Cargo.toml -[rcfg]: ./src/rollup_config.rs - -[serde]: https://crates.io/crates/serde -[sp]: https://crates.io/crates/superchain-primitives - - diff --git a/bindings/rust-primitives/justfile b/bindings/rust-primitives/justfile deleted file mode 100644 index bd92ae78f..000000000 --- a/bindings/rust-primitives/justfile +++ /dev/null @@ -1,61 +0,0 @@ -set positional-arguments -alias t := tests -alias l := lint -alias f := fmt -alias b := build - -# default recipe to display help information -default: - @just --list - -# Runs everything needed for ci -ci: fmt lint tests - -# Run all tests -tests: test test-features test-docs - -# Formats -fmt: fmt-fix fmt-check - -# Lint the workspace for all available targets -lint: lint-source lint-source-features lint-docs - -# Build for the native target -build *args='': - cargo build --workspace --all $@ - -# Fixes the formatting -fmt-fix: - cargo +nightly fmt --all - -# Check the formatting -fmt-check: - cargo +nightly fmt --all -- --check - -# Lint the workspace -lint-source: fmt-check - cargo +nightly clippy --all --all-targets -- -D warnings - -# Lint the workspace -lint-source-features: fmt-check - cargo +nightly clippy --all --all-features --all-targets -- -D warnings - -# Lint the Rust documentation -lint-docs: - RUSTDOCFLAGS="-D warnings" cargo doc --all --no-deps --document-private-items - -# Test without features -test *args='': - cargo nextest run --all $@ - -# Test for the native target with all features -test-features *args='': - cargo nextest run --all --all-features $@ - -# Test the Rust documentation -test-docs: - cargo test --doc --all --locked - -# Release the crate -release: - cargo release publish --execute --no-confirm diff --git a/bindings/rust-primitives/src/addresses.rs b/bindings/rust-primitives/src/addresses.rs deleted file mode 100644 index 725431584..000000000 --- a/bindings/rust-primitives/src/addresses.rs +++ /dev/null @@ -1,86 +0,0 @@ -//! Address Types - -use alloy_primitives::Address; - -/// The set of network-specific contracts for a given chain. -#[derive(Debug, Clone, Hash, PartialEq, Eq, Default)] -#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -#[cfg_attr(feature = "serde", serde(rename_all = "PascalCase"))] -pub struct AddressList { - /// The address manager - pub address_manager: Address, - /// L1 Cross Domain Messenger proxy address - pub l1_cross_domain_messenger_proxy: Address, - /// L1 ERC721 Bridge proxy address - #[cfg_attr(feature = "serde", serde(alias = "L1ERC721BridgeProxy"))] - pub l1_erc721_bridge_proxy: Address, - /// L1 Standard Bridge proxy address - pub l1_standard_bridge_proxy: Address, - /// L2 Output Oracle Proxy address - pub l2_output_oracle_proxy: Option
, - /// Optimism Mintable ERC20 Factory Proxy address - #[cfg_attr(feature = "serde", serde(alias = "OptimismMintableERC20FactoryProxy"))] - pub optimism_mintable_erc20_factory_proxy: Address, - /// Optimism Portal Proxy address - pub optimism_portal_proxy: Address, - /// System Config Proxy address - pub system_config_proxy: Address, - /// The system config owner - pub system_config_owner: Address, - /// Proxy Admin address - pub proxy_admin: Address, - /// The owner of the Proxy Admin - pub proxy_admin_owner: Address, - /// The guardian address - pub guardian: Address, - - // Fault Proof Contract Addresses - /// Anchor State Registry Proxy address - pub anchor_state_registry_proxy: Option
, - /// Delayed WETH Proxy address - #[cfg_attr(feature = "serde", serde(alias = "DelayedWETHProxy"))] - pub delayed_weth_proxy: Option
, - /// Dispute Game Factory Proxy address - pub dispute_game_factory_proxy: Option
, - /// Fault Dispute Game Proxy address - pub fault_dispute_game: Option
, - /// MIPS Proxy address - #[cfg_attr(feature = "serde", serde(alias = "MIPS"))] - pub mips: Option
, - /// Permissioned Dispute Game Proxy address - pub permissioned_dispute_game: Option
, - /// Preimage Oracle Proxy address - pub preimage_oracle: Option
, - /// The challenger's address - pub challenger: Option
, -} - -impl AddressList { - /// Sets zeroed addresses to [`Option::None`]. - pub fn zero_proof_addresses(&mut self) { - if self.anchor_state_registry_proxy == Some(Address::ZERO) { - self.anchor_state_registry_proxy = None; - } - if self.delayed_weth_proxy == Some(Address::ZERO) { - self.delayed_weth_proxy = None; - } - if self.dispute_game_factory_proxy == Some(Address::ZERO) { - self.dispute_game_factory_proxy = None; - } - if self.fault_dispute_game == Some(Address::ZERO) { - self.fault_dispute_game = None; - } - if self.mips == Some(Address::ZERO) { - self.mips = None; - } - if self.permissioned_dispute_game == Some(Address::ZERO) { - self.permissioned_dispute_game = None; - } - if self.preimage_oracle == Some(Address::ZERO) { - self.preimage_oracle = None; - } - if self.challenger == Some(Address::ZERO) { - self.challenger = None; - } - } -} diff --git a/bindings/rust-primitives/src/block.rs b/bindings/rust-primitives/src/block.rs deleted file mode 100644 index 73622c965..000000000 --- a/bindings/rust-primitives/src/block.rs +++ /dev/null @@ -1,24 +0,0 @@ -//! Block Types - -use alloy_primitives::B256; -use core::fmt::Display; - -/// Block identifier. -#[derive(Debug, Clone, Copy, Eq, Hash, PartialEq, Default)] -#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -pub struct BlockID { - /// Block hash - pub hash: B256, - /// Block number - pub number: u64, -} - -impl Display for BlockID { - fn fmt(&self, f: &mut core::fmt::Formatter<'_>) -> core::fmt::Result { - write!( - f, - "BlockID {{ hash: {}, number: {} }}", - self.hash, self.number - ) - } -} diff --git a/bindings/rust-primitives/src/chain_config.rs b/bindings/rust-primitives/src/chain_config.rs deleted file mode 100644 index 277887301..000000000 --- a/bindings/rust-primitives/src/chain_config.rs +++ /dev/null @@ -1,112 +0,0 @@ -//! Chain Config Types - -use crate::AddressList; -use crate::ChainGenesis; -use crate::SuperchainLevel; -use alloc::string::String; -use alloy_primitives::Address; - -/// AltDA configuration. -#[derive(Debug, Clone, Default, Hash, Eq, PartialEq)] -#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -pub struct AltDAConfig { - /// AltDA challenge address - pub da_challenge_address: Option
, - /// AltDA challenge window time (in seconds) - pub da_challenge_window: Option, - /// AltDA resolution window time (in seconds) - pub da_resolve_window: Option, -} - -/// Hardfork configuration. -#[derive(Debug, Clone, Default, Hash, Eq, PartialEq)] -#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -pub struct HardForkConfiguration { - /// Canyon hardfork activation time - pub canyon_time: Option, - /// Delta hardfork activation time - pub delta_time: Option, - /// Ecotone hardfork activation time - pub ecotone_time: Option, - /// Fjord hardfork activation time - pub fjord_time: Option, - /// Granite hardfork activation time - pub granite_time: Option, - /// Holocene hardfork activation time - pub holocene_time: Option, -} - -/// A chain configuration. -#[derive(Debug, Clone, Default, Hash, Eq, PartialEq)] -#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -pub struct ChainConfig { - /// Chain name (e.g. "Base") - pub name: String, - /// Chain ID - pub chain_id: u64, - /// L1 chain ID - #[cfg_attr(feature = "serde", serde(skip))] - pub l1_chain_id: u64, - /// Chain public RPC endpoint - pub public_rpc: String, - /// Chain sequencer RPC endpoint - pub sequencer_rpc: String, - /// Chain explorer HTTP endpoint - pub explorer: String, - /// Level of integration with the superchain. - pub superchain_level: SuperchainLevel, - /// Time of opt-in to the Superchain. - /// If superchain_time is set, hardforks times after superchain_time - /// will be inherited from the superchain-wide config. - pub superchain_time: Option, - /// Chain-specific batch inbox address - pub batch_inbox_addr: Address, - /// Chain-specific genesis information - pub genesis: ChainGenesis, - /// Superchain is a simple string to identify the superchain. - /// This is implied by directory structure, and not encoded in the config file itself. - #[cfg_attr(feature = "serde", serde(skip))] - pub superchain: String, - /// Chain is a simple string to identify the chain, within its superchain context. - /// This matches the resource filename, it is not encoded in the config file itself. - #[cfg_attr(feature = "serde", serde(skip))] - pub chain: String, - /// Hardfork Configuration. These values may override the superchain-wide defaults. - #[cfg_attr(feature = "serde", serde(flatten))] - pub hardfork_configuration: HardForkConfiguration, - /// Optional AltDA feature - pub alt_da: Option, - /// Addresses - pub addresses: Option, -} - -impl ChainConfig { - /// Set missing hardfork configurations to the defaults, if the chain has - /// a superchain_time set. Defaults are only used if the chain's hardfork - /// activated after the superchain_time. - pub fn set_missing_fork_configs(&mut self, defaults: &HardForkConfiguration) { - let Some(super_time) = self.superchain_time else { - return; - }; - let cfg = &mut self.hardfork_configuration; - - if cfg.canyon_time.is_none() && defaults.canyon_time.is_some_and(|t| t > super_time) { - cfg.canyon_time = defaults.canyon_time; - } - if cfg.delta_time.is_none() && defaults.delta_time.is_some_and(|t| t > super_time) { - cfg.delta_time = defaults.delta_time; - } - if cfg.ecotone_time.is_none() && defaults.ecotone_time.is_some_and(|t| t > super_time) { - cfg.ecotone_time = defaults.ecotone_time; - } - if cfg.fjord_time.is_none() && defaults.fjord_time.is_some_and(|t| t > super_time) { - cfg.fjord_time = defaults.fjord_time; - } - if cfg.granite_time.is_none() && defaults.granite_time.is_some_and(|t| t > super_time) { - cfg.granite_time = defaults.granite_time; - } - if cfg.holocene_time.is_none() && defaults.holocene_time.is_some_and(|t| t > super_time) { - cfg.holocene_time = defaults.holocene_time; - } - } -} diff --git a/bindings/rust-primitives/src/fee_params.rs b/bindings/rust-primitives/src/fee_params.rs deleted file mode 100644 index dd0539030..000000000 --- a/bindings/rust-primitives/src/fee_params.rs +++ /dev/null @@ -1,89 +0,0 @@ -//! Module containing fee parameters. - -use alloy_eips::eip1559::BaseFeeParams; - -/// Returns the [BaseFeeParams] for the given chain id. -pub fn base_fee_params(chain_id: u64) -> BaseFeeParams { - match chain_id { - 10 => OP_BASE_FEE_PARAMS, - 11155420 => OP_SEPOLIA_BASE_FEE_PARAMS, - 8453 => OP_BASE_FEE_PARAMS, - 84532 => BASE_SEPOLIA_BASE_FEE_PARAMS, - _ => OP_BASE_FEE_PARAMS, - } -} - -/// Returns the Canyon [BaseFeeParams] for the given chain id. -pub fn canyon_base_fee_params(chain_id: u64) -> BaseFeeParams { - match chain_id { - 10 => OP_CANYON_BASE_FEE_PARAMS, - 11155420 => OP_SEPOLIA_CANYON_BASE_FEE_PARAMS, - 8453 => OP_CANYON_BASE_FEE_PARAMS, - 84532 => BASE_SEPOLIA_CANYON_BASE_FEE_PARAMS, - _ => OP_CANYON_BASE_FEE_PARAMS, - } -} - -/// Base fee max change denominator for Optimism Mainnet as defined in the Optimism -/// [transaction costs](https://community.optimism.io/docs/developers/build/differences/#transaction-costs) doc. -pub const OP_MAINNET_EIP1559_DEFAULT_BASE_FEE_MAX_CHANGE_DENOMINATOR: u128 = 50; - -/// Base fee max change denominator for Optimism Mainnet as defined in the Optimism Canyon -/// hardfork. -pub const OP_MAINNET_EIP1559_BASE_FEE_MAX_CHANGE_DENOMINATOR_CANYON: u128 = 250; - -/// Base fee max change denominator for Optimism Mainnet as defined in the Optimism -/// [transaction costs](https://community.optimism.io/docs/developers/build/differences/#transaction-costs) doc. -pub const OP_MAINNET_EIP1559_DEFAULT_ELASTICITY_MULTIPLIER: u128 = 6; - -/// Base fee max change denominator for Optimism Sepolia as defined in the Optimism -/// [transaction costs](https://community.optimism.io/docs/developers/build/differences/#transaction-costs) doc. -pub const OP_SEPOLIA_EIP1559_DEFAULT_BASE_FEE_MAX_CHANGE_DENOMINATOR: u128 = 50; - -/// Base fee max change denominator for Optimism Sepolia as defined in the Optimism Canyon -/// hardfork. -pub const OP_SEPOLIA_EIP1559_BASE_FEE_MAX_CHANGE_DENOMINATOR_CANYON: u128 = 250; - -/// Base fee max change denominator for Optimism Sepolia as defined in the Optimism -/// [transaction costs](https://community.optimism.io/docs/developers/build/differences/#transaction-costs) doc. -pub const OP_SEPOLIA_EIP1559_DEFAULT_ELASTICITY_MULTIPLIER: u128 = 6; - -/// Base fee max change denominator for Base Sepolia as defined in the Optimism -/// [transaction costs](https://community.optimism.io/docs/developers/build/differences/#transaction-costs) doc. -pub const BASE_SEPOLIA_EIP1559_DEFAULT_ELASTICITY_MULTIPLIER: u128 = 10; - -/// Get the base fee parameters for Optimism Sepolia. -pub const OP_SEPOLIA_BASE_FEE_PARAMS: BaseFeeParams = BaseFeeParams { - max_change_denominator: OP_SEPOLIA_EIP1559_DEFAULT_BASE_FEE_MAX_CHANGE_DENOMINATOR, - elasticity_multiplier: OP_SEPOLIA_EIP1559_DEFAULT_ELASTICITY_MULTIPLIER, -}; - -/// Get the base fee parameters for Optimism Sepolia (post Canyon). -pub const OP_SEPOLIA_CANYON_BASE_FEE_PARAMS: BaseFeeParams = BaseFeeParams { - max_change_denominator: OP_SEPOLIA_EIP1559_BASE_FEE_MAX_CHANGE_DENOMINATOR_CANYON, - elasticity_multiplier: OP_SEPOLIA_EIP1559_DEFAULT_ELASTICITY_MULTIPLIER, -}; - -/// Get the base fee parameters for Base Sepolia. -pub const BASE_SEPOLIA_BASE_FEE_PARAMS: BaseFeeParams = BaseFeeParams { - max_change_denominator: OP_SEPOLIA_EIP1559_DEFAULT_BASE_FEE_MAX_CHANGE_DENOMINATOR, - elasticity_multiplier: BASE_SEPOLIA_EIP1559_DEFAULT_ELASTICITY_MULTIPLIER, -}; - -/// Get the base fee parameters for Base Sepolia (post Canyon). -pub const BASE_SEPOLIA_CANYON_BASE_FEE_PARAMS: BaseFeeParams = BaseFeeParams { - max_change_denominator: OP_SEPOLIA_EIP1559_BASE_FEE_MAX_CHANGE_DENOMINATOR_CANYON, - elasticity_multiplier: BASE_SEPOLIA_EIP1559_DEFAULT_ELASTICITY_MULTIPLIER, -}; - -/// Get the base fee parameters for Optimism Mainnet. -pub const OP_BASE_FEE_PARAMS: BaseFeeParams = BaseFeeParams { - max_change_denominator: OP_MAINNET_EIP1559_DEFAULT_BASE_FEE_MAX_CHANGE_DENOMINATOR, - elasticity_multiplier: OP_MAINNET_EIP1559_DEFAULT_ELASTICITY_MULTIPLIER, -}; - -/// Get the base fee parameters for Optimism Mainnet (post Canyon). -pub const OP_CANYON_BASE_FEE_PARAMS: BaseFeeParams = BaseFeeParams { - max_change_denominator: OP_MAINNET_EIP1559_BASE_FEE_MAX_CHANGE_DENOMINATOR_CANYON, - elasticity_multiplier: OP_MAINNET_EIP1559_DEFAULT_ELASTICITY_MULTIPLIER, -}; diff --git a/bindings/rust-primitives/src/genesis.rs b/bindings/rust-primitives/src/genesis.rs deleted file mode 100644 index 10b094d90..000000000 --- a/bindings/rust-primitives/src/genesis.rs +++ /dev/null @@ -1,21 +0,0 @@ -//! Genesis types. - -use crate::BlockID; -use crate::SystemConfig; -use alloy_primitives::Bytes; - -/// Chain genesis information. -#[derive(Debug, Clone, Default, Hash, Eq, PartialEq)] -#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -pub struct ChainGenesis { - /// L1 genesis block - pub l1: BlockID, - /// L2 genesis block - pub l2: BlockID, - /// Timestamp of the L2 genesis block - pub l2_time: u64, - /// Extra data for the genesis block - pub extra_data: Option, - /// Optional System configuration - pub system_config: Option, -} diff --git a/bindings/rust-primitives/src/lib.rs b/bindings/rust-primitives/src/lib.rs deleted file mode 100644 index b10f44ba2..000000000 --- a/bindings/rust-primitives/src/lib.rs +++ /dev/null @@ -1,53 +0,0 @@ -#![doc = include_str!("../README.md")] -#![warn(missing_debug_implementations, missing_docs, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] -#![cfg_attr(not(test), warn(unused_crate_dependencies))] -#![cfg_attr(not(feature = "std"), no_std)] - -extern crate alloc; - -/// Re-export the Genesis type from [alloy_genesis]. -pub use alloy_genesis::Genesis; - -pub mod superchain; -pub use superchain::{Superchain, SuperchainConfig, SuperchainL1Info, SuperchainLevel}; - -pub mod predeploys; -pub use predeploys::{ - BASE_FEE_VAULT, BEACON_BLOCK_ROOT, EAS, GAS_PRICE_ORACLE, GOVERNANCE_TOKEN, L1_BLOCK, - L1_BLOCK_NUMBER, L1_FEE_VAULT, L2_CROSS_DOMAIN_MESSENGER, L2_ERC721_BRIDGE, L2_STANDARD_BRIDGE, - L2_TO_L1_MESSAGE_PASSER, OPTIMISM_MINTABLE_ERC20_FACTORY, OPTIMISM_MINTABLE_ERC721_FACTORY, - PROXY_ADMIN, SCHEMA_REGISTRY, SEQUENCER_FEE_VAULT, WETH9, -}; - -pub mod fee_params; -pub use fee_params::{ - BASE_SEPOLIA_BASE_FEE_PARAMS, BASE_SEPOLIA_CANYON_BASE_FEE_PARAMS, - BASE_SEPOLIA_EIP1559_DEFAULT_ELASTICITY_MULTIPLIER, OP_BASE_FEE_PARAMS, - OP_CANYON_BASE_FEE_PARAMS, OP_SEPOLIA_BASE_FEE_PARAMS, OP_SEPOLIA_CANYON_BASE_FEE_PARAMS, - OP_SEPOLIA_EIP1559_BASE_FEE_MAX_CHANGE_DENOMINATOR_CANYON, - OP_SEPOLIA_EIP1559_DEFAULT_BASE_FEE_MAX_CHANGE_DENOMINATOR, - OP_SEPOLIA_EIP1559_DEFAULT_ELASTICITY_MULTIPLIER, -}; - -pub mod rollup_config; -pub use rollup_config::{ - load_op_stack_rollup_config, rollup_config_from_chain_id, RollupConfig, BASE_MAINNET_CONFIG, - BASE_SEPOLIA_CONFIG, OP_MAINNET_CONFIG, OP_SEPOLIA_CONFIG, -}; - -pub mod chain_config; -pub use chain_config::{AltDAConfig, ChainConfig, HardForkConfiguration}; - -pub mod genesis; -pub use genesis::ChainGenesis; - -pub mod block; -pub use block::BlockID; - -pub mod system_config; -pub use system_config::SystemConfig; - -pub mod addresses; -pub use addresses::AddressList; diff --git a/bindings/rust-primitives/src/predeploys.rs b/bindings/rust-primitives/src/predeploys.rs deleted file mode 100644 index c478e7175..000000000 --- a/bindings/rust-primitives/src/predeploys.rs +++ /dev/null @@ -1,83 +0,0 @@ -//! Contains all [predeploy contract addresses][predeploys]. -//! -//! Predeploys are smart contracts on the OP Stack that exist at predetermined addresses -//! at the genesis state. They are similar to precompiles but run directly in the EVM -//! instead of running native code outside of the EVM. -//! -//! Predeploys are used instead of precompiles to make it easier for multiclient -//! implementations and allow for more integration with hardhat/foundry network forking. -//! -//! Predeploy addresses exist in the 1-byte namespace `0x42000000000000000000000000000000000000xx`. -//! Proxies are set at each possible predeploy address except for the GovernanceToken and the ProxyAdmin. -//! -//! [predeploys]: https://specs.optimism.io/protocol/predeploys.html - -use alloy_primitives::{address, Address}; - -/// Legacy Message Passer Predeploy. -#[deprecated] -pub const LEGACY_MESSAGE_PASSER: Address = address!("4200000000000000000000000000000000000000"); - -/// Deployer Whitelist Predeploy. -#[deprecated] -pub const DEPLOYER_WHITELIST: Address = address!("4200000000000000000000000000000000000002"); - -/// Legacy ERC20ETH Predeploy. -#[deprecated] -pub const LEGACY_ERC20_ETH: Address = address!("DeadDeAddeAddEAddeadDEaDDEAdDeaDDeAD0000"); - -/// WETH9 Predeploy. -pub const WETH9: Address = address!("4200000000000000000000000000000000000006"); - -/// L2 Cross Domain Messenger Predeploy. -pub const L2_CROSS_DOMAIN_MESSENGER: Address = address!("4200000000000000000000000000000000000007"); - -/// L2 Standard Bridge Predeploy. -pub const L2_STANDARD_BRIDGE: Address = address!("4200000000000000000000000000000000000010"); - -/// Sequencer Fee Vault Predeploy. -pub const SEQUENCER_FEE_VAULT: Address = address!("4200000000000000000000000000000000000011"); - -/// Optimism Mintable ERC20 Factory Predeploy. -pub const OPTIMISM_MINTABLE_ERC20_FACTORY: Address = - address!("4200000000000000000000000000000000000012"); - -/// L1 Block Number Predeploy. -pub const L1_BLOCK_NUMBER: Address = address!("4200000000000000000000000000000000000013"); - -/// Gas Price Oracle Predeploy. -pub const GAS_PRICE_ORACLE: Address = address!("420000000000000000000000000000000000000F"); - -/// Governance Token Predeploy. -pub const GOVERNANCE_TOKEN: Address = address!("4200000000000000000000000000000000000042"); - -/// L1 Block Predeploy. -pub const L1_BLOCK: Address = address!("4200000000000000000000000000000000000015"); - -/// L2 To L1 Message Passer Predeploy. -pub const L2_TO_L1_MESSAGE_PASSER: Address = address!("4200000000000000000000000000000000000016"); - -/// L2 ERC721 Bridge Predeploy. -pub const L2_ERC721_BRIDGE: Address = address!("4200000000000000000000000000000000000014"); - -/// Optimism Mintable ERC721 Factory Predeploy. -pub const OPTIMISM_MINTABLE_ERC721_FACTORY: Address = - address!("4200000000000000000000000000000000000017"); - -/// Proxy Admin Predeploy. -pub const PROXY_ADMIN: Address = address!("4200000000000000000000000000000000000018"); - -/// Base Fee Vault Predeploy. -pub const BASE_FEE_VAULT: Address = address!("4200000000000000000000000000000000000019"); - -/// L1 Fee Vault Predeploy. -pub const L1_FEE_VAULT: Address = address!("420000000000000000000000000000000000001a"); - -/// Schema Registry Predeploy. -pub const SCHEMA_REGISTRY: Address = address!("4200000000000000000000000000000000000020"); - -/// EAS Predeploy. -pub const EAS: Address = address!("4200000000000000000000000000000000000021"); - -/// Beacon Block Root Predeploy. -pub const BEACON_BLOCK_ROOT: Address = address!("000F3df6D732807Ef1319fB7B8bB8522d0Beac02"); diff --git a/bindings/rust-primitives/src/rollup_config.rs b/bindings/rust-primitives/src/rollup_config.rs deleted file mode 100644 index cb33ab095..000000000 --- a/bindings/rust-primitives/src/rollup_config.rs +++ /dev/null @@ -1,621 +0,0 @@ -//! Rollup Config Types - -use alloy_eips::eip1559::BaseFeeParams; -use alloy_primitives::{address, b256, uint, Address}; -use anyhow::{anyhow, Result}; - -use crate::block::BlockID; -use crate::chain_config::ChainConfig; -use crate::fee_params::{ - base_fee_params, canyon_base_fee_params, BASE_SEPOLIA_BASE_FEE_PARAMS, - BASE_SEPOLIA_CANYON_BASE_FEE_PARAMS, OP_BASE_FEE_PARAMS, OP_CANYON_BASE_FEE_PARAMS, - OP_SEPOLIA_BASE_FEE_PARAMS, OP_SEPOLIA_CANYON_BASE_FEE_PARAMS, -}; -use crate::genesis::ChainGenesis; -use crate::system_config::SystemConfig; - -/// The max rlp bytes per channel for the Bedrock hardfork. -pub const MAX_RLP_BYTES_PER_CHANNEL_BEDROCK: u64 = 10_000_000; - -/// The max rlp bytes per channel for the Fjord hardfork. -pub const MAX_RLP_BYTES_PER_CHANNEL_FJORD: u64 = 100_000_000; - -/// The max sequencer drift when the Fjord hardfork is active. -pub const FJORD_MAX_SEQUENCER_DRIFT: u64 = 1800; - -/// The channel timeout once the Granite hardfork is active. -pub const GRANITE_CHANNEL_TIMEOUT: u64 = 50; - -fn default_granite_channel_timeout() -> u64 { - GRANITE_CHANNEL_TIMEOUT -} - -/// Returns the rollup config for the given chain ID. -pub fn rollup_config_from_chain_id(chain_id: u64) -> Result { - chain_id.try_into() -} - -impl TryFrom for RollupConfig { - type Error = anyhow::Error; - - fn try_from(chain_id: u64) -> Result { - match chain_id { - 10 => Ok(OP_MAINNET_CONFIG), - 11155420 => Ok(OP_SEPOLIA_CONFIG), - 8453 => Ok(BASE_MAINNET_CONFIG), - 84532 => Ok(BASE_SEPOLIA_CONFIG), - _ => Err(anyhow!("Unknown chain ID")), - } - } -} - -/// The Rollup configuration. -#[derive(Debug, Clone, Eq, PartialEq)] -#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -pub struct RollupConfig { - /// The genesis state of the rollup. - pub genesis: ChainGenesis, - /// The block time of the L2, in seconds. - pub block_time: u64, - /// Sequencer batches may not be more than MaxSequencerDrift seconds after - /// the L1 timestamp of the sequencing window end. - /// - /// Note: When L1 has many 1 second consecutive blocks, and L2 grows at fixed 2 seconds, - /// the L2 time may still grow beyond this difference. - /// - /// Note: After the Fjord hardfork, this value becomes a constant of `1800`. - pub max_sequencer_drift: u64, - /// The sequencer window size. - pub seq_window_size: u64, - /// Number of L1 blocks between when a channel can be opened and when it can be closed. - pub channel_timeout: u64, - /// The channel timeout after the Granite hardfork. - #[cfg_attr(feature = "serde", serde(default = "default_granite_channel_timeout"))] - pub granite_channel_timeout: u64, - /// The L1 chain ID - pub l1_chain_id: u64, - /// The L2 chain ID - pub l2_chain_id: u64, - /// Base Fee Params - pub base_fee_params: BaseFeeParams, - /// Base fee params post-canyon hardfork - #[cfg_attr(feature = "serde", serde(skip_serializing_if = "Option::is_none"))] - pub canyon_base_fee_params: Option, - /// `regolith_time` sets the activation time of the Regolith network-upgrade: - /// a pre-mainnet Bedrock change that addresses findings of the Sherlock contest related to - /// deposit attributes. "Regolith" is the loose deposited rock that sits on top of Bedrock. - /// Active if regolith_time != None && L2 block timestamp >= Some(regolith_time), inactive - /// otherwise. - #[cfg_attr(feature = "serde", serde(skip_serializing_if = "Option::is_none"))] - pub regolith_time: Option, - /// `canyon_time` sets the activation time of the Canyon network upgrade. - /// Active if `canyon_time` != None && L2 block timestamp >= Some(canyon_time), inactive - /// otherwise. - #[cfg_attr(feature = "serde", serde(skip_serializing_if = "Option::is_none"))] - pub canyon_time: Option, - /// `delta_time` sets the activation time of the Delta network upgrade. - /// Active if `delta_time` != None && L2 block timestamp >= Some(delta_time), inactive - /// otherwise. - #[cfg_attr(feature = "serde", serde(skip_serializing_if = "Option::is_none"))] - pub delta_time: Option, - /// `ecotone_time` sets the activation time of the Ecotone network upgrade. - /// Active if `ecotone_time` != None && L2 block timestamp >= Some(ecotone_time), inactive - /// otherwise. - #[cfg_attr(feature = "serde", serde(skip_serializing_if = "Option::is_none"))] - pub ecotone_time: Option, - /// `fjord_time` sets the activation time of the Fjord network upgrade. - /// Active if `fjord_time` != None && L2 block timestamp >= Some(fjord_time), inactive - /// otherwise. - #[cfg_attr(feature = "serde", serde(skip_serializing_if = "Option::is_none"))] - pub fjord_time: Option, - /// `granite_time` sets the activation time for the Granite network upgrade. - /// Active if `granite_time` != None && L2 block timestamp >= Some(granite_time), inactive - /// otherwise. - #[cfg_attr(feature = "serde", serde(skip_serializing_if = "Option::is_none"))] - pub granite_time: Option, - /// `holocene_time` sets the activation time for the Holocene network upgrade. - /// Active if `holocene_time` != None && L2 block timestamp >= Some(holocene_time), inactive - /// otherwise. - #[cfg_attr(feature = "serde", serde(skip_serializing_if = "Option::is_none"))] - pub holocene_time: Option, - /// `batch_inbox_address` is the L1 address that batches are sent to. - pub batch_inbox_address: Address, - /// `deposit_contract_address` is the L1 address that deposits are sent to. - pub deposit_contract_address: Address, - /// `l1_system_config_address` is the L1 address that the system config is stored at. - pub l1_system_config_address: Address, - /// `protocol_versions_address` is the L1 address that the protocol versions are stored at. - pub protocol_versions_address: Address, - /// The superchain config address. - #[cfg_attr(feature = "serde", serde(skip_serializing_if = "Option::is_none"))] - pub superchain_config_address: Option
, - /// `blobs_enabled_l1_timestamp` is the timestamp to start reading blobs as a batch data - /// source. Optional. - #[cfg_attr( - feature = "serde", - serde(rename = "blobs_data", skip_serializing_if = "Option::is_none") - )] - pub blobs_enabled_l1_timestamp: Option, - /// `da_challenge_address` is the L1 address that the data availability challenge contract is - /// stored at. - #[cfg_attr(feature = "serde", serde(skip_serializing_if = "Option::is_none"))] - pub da_challenge_address: Option
, -} - -// Need to manually implement Default because [`BaseFeeParams`] has no Default impl. -impl Default for RollupConfig { - fn default() -> Self { - RollupConfig { - genesis: ChainGenesis::default(), - block_time: 0, - max_sequencer_drift: 0, - seq_window_size: 0, - channel_timeout: 0, - granite_channel_timeout: GRANITE_CHANNEL_TIMEOUT, - l1_chain_id: 0, - l2_chain_id: 0, - base_fee_params: OP_BASE_FEE_PARAMS, - canyon_base_fee_params: None, - regolith_time: None, - canyon_time: None, - delta_time: None, - ecotone_time: None, - fjord_time: None, - granite_time: None, - holocene_time: None, - batch_inbox_address: Address::ZERO, - deposit_contract_address: Address::ZERO, - l1_system_config_address: Address::ZERO, - protocol_versions_address: Address::ZERO, - superchain_config_address: None, - blobs_enabled_l1_timestamp: None, - da_challenge_address: None, - } - } -} - -/// Loads the rollup config for the OP-Stack chain given the chain config and address list. -pub fn load_op_stack_rollup_config(chain_config: &ChainConfig) -> RollupConfig { - RollupConfig { - genesis: chain_config.genesis.clone(), - l1_chain_id: chain_config.l1_chain_id, - l2_chain_id: chain_config.chain_id, - base_fee_params: base_fee_params(chain_config.chain_id), - canyon_base_fee_params: Some(canyon_base_fee_params(chain_config.chain_id)), - regolith_time: Some(0), - canyon_time: chain_config.hardfork_configuration.canyon_time, - delta_time: chain_config.hardfork_configuration.delta_time, - ecotone_time: chain_config.hardfork_configuration.ecotone_time, - fjord_time: chain_config.hardfork_configuration.fjord_time, - granite_time: chain_config.hardfork_configuration.granite_time, - holocene_time: chain_config.hardfork_configuration.holocene_time, - batch_inbox_address: chain_config.batch_inbox_addr, - deposit_contract_address: chain_config - .addresses - .as_ref() - .map(|a| a.optimism_portal_proxy) - .unwrap_or_default(), - l1_system_config_address: chain_config - .addresses - .as_ref() - .map(|a| a.system_config_proxy) - .unwrap_or_default(), - protocol_versions_address: chain_config - .addresses - .as_ref() - .map(|a| a.address_manager) - .unwrap_or_default(), - superchain_config_address: None, - blobs_enabled_l1_timestamp: None, - da_challenge_address: chain_config - .alt_da - .as_ref() - .and_then(|alt_da| alt_da.da_challenge_address), - - // The below chain parameters can be different per OP-Stack chain, - // but since none of the superchain chains differ, it's not represented in the superchain-registry yet. - // This restriction on superchain-chains may change in the future. - // Test/Alt configurations can still load custom rollup-configs when necessary. - block_time: 2, - channel_timeout: 300, - granite_channel_timeout: GRANITE_CHANNEL_TIMEOUT, - max_sequencer_drift: 600, - seq_window_size: 3600, - } -} - -impl RollupConfig { - /// Returns true if Regolith is active at the given timestamp. - pub fn is_regolith_active(&self, timestamp: u64) -> bool { - self.regolith_time.map_or(false, |t| timestamp >= t) - } - - /// Returns true if Canyon is active at the given timestamp. - pub fn is_canyon_active(&self, timestamp: u64) -> bool { - self.canyon_time.map_or(false, |t| timestamp >= t) - } - - /// Returns true if Delta is active at the given timestamp. - pub fn is_delta_active(&self, timestamp: u64) -> bool { - self.delta_time.map_or(false, |t| timestamp >= t) - } - - /// Returns true if Ecotone is active at the given timestamp. - pub fn is_ecotone_active(&self, timestamp: u64) -> bool { - self.ecotone_time.map_or(false, |t| timestamp >= t) - } - - /// Returns true if Fjord is active at the given timestamp. - pub fn is_fjord_active(&self, timestamp: u64) -> bool { - self.fjord_time.map_or(false, |t| timestamp >= t) - } - - /// Returns true if Granite is active at the given timestamp. - pub fn is_granite_active(&self, timestamp: u64) -> bool { - self.granite_time.map_or(false, |t| timestamp >= t) - } - - /// Returns true if Holocene is active at the given timestamp. - pub fn is_holocene_active(&self, timestamp: u64) -> bool { - self.holocene_time.map_or(false, |t| timestamp >= t) - } - - /// Returns true if a DA Challenge proxy Address is provided in the rollup config and the - /// address is not zero. - pub fn is_alt_da_enabled(&self) -> bool { - self.da_challenge_address - .map_or(false, |addr| !addr.is_zero()) - } - - /// Returns the max sequencer drift for the given timestamp. - pub fn max_sequencer_drift(&self, timestamp: u64) -> u64 { - if self.is_fjord_active(timestamp) { - FJORD_MAX_SEQUENCER_DRIFT - } else { - self.max_sequencer_drift - } - } - - /// Returns the max rlp bytes per channel for the given timestamp. - pub fn max_rlp_bytes_per_channel(&self, timestamp: u64) -> u64 { - if self.is_fjord_active(timestamp) { - MAX_RLP_BYTES_PER_CHANNEL_FJORD - } else { - MAX_RLP_BYTES_PER_CHANNEL_BEDROCK - } - } - - /// Returns the channel timeout for the given timestamp. - pub fn channel_timeout(&self, timestamp: u64) -> u64 { - if self.is_granite_active(timestamp) { - self.granite_channel_timeout - } else { - self.channel_timeout - } - } - - /// Checks the scalar value in Ecotone. - pub fn check_ecotone_l1_system_config_scalar(scalar: [u8; 32]) -> Result<(), &'static str> { - let version_byte = scalar[0]; - match version_byte { - 0 => { - if scalar[1..28] != [0; 27] { - return Err("Bedrock scalar padding not empty"); - } - Ok(()) - } - 1 => { - if scalar[1..24] != [0; 23] { - return Err("Invalid version 1 scalar padding"); - } - Ok(()) - } - _ => { - // ignore the event if it's an unknown scalar format - Err("Unrecognized scalar version") - } - } - } - - /// Returns the [RollupConfig] for the given L2 chain ID. - pub fn from_l2_chain_id(l2_chain_id: u64) -> Option { - match l2_chain_id { - 10 => Some(OP_MAINNET_CONFIG), - 11155420 => Some(OP_SEPOLIA_CONFIG), - 8453 => Some(BASE_MAINNET_CONFIG), - 84532 => Some(BASE_SEPOLIA_CONFIG), - _ => None, - } - } -} - -/// The [RollupConfig] for OP Mainnet. -pub const OP_MAINNET_CONFIG: RollupConfig = RollupConfig { - genesis: ChainGenesis { - l1: BlockID { - hash: b256!("438335a20d98863a4c0c97999eb2481921ccd28553eac6f913af7c12aec04108"), - number: 17_422_590_u64, - }, - l2: BlockID { - hash: b256!("dbf6a80fef073de06add9b0d14026d6e5a86c85f6d102c36d3d8e9cf89c2afd3"), - number: 105_235_063_u64, - }, - l2_time: 1_686_068_903_u64, - system_config: Some(SystemConfig { - batcher_address: address!("6887246668a3b87f54deb3b94ba47a6f63f32985"), - overhead: uint!(0xbc_U256), - scalar: uint!(0xa6fe0_U256), - gas_limit: 30_000_000_u64, - base_fee_scalar: None, - blob_base_fee_scalar: None, - }), - extra_data: None, - }, - block_time: 2_u64, - max_sequencer_drift: 600_u64, - seq_window_size: 3600_u64, - channel_timeout: 300_u64, - granite_channel_timeout: 50, - l1_chain_id: 1_u64, - l2_chain_id: 10_u64, - base_fee_params: OP_BASE_FEE_PARAMS, - canyon_base_fee_params: Some(OP_CANYON_BASE_FEE_PARAMS), - regolith_time: Some(0_u64), - canyon_time: Some(1_704_992_401_u64), - delta_time: Some(1_708_560_000_u64), - ecotone_time: Some(1_710_374_401_u64), - fjord_time: Some(1_720_627_201_u64), - granite_time: Some(1_726_070_401_u64), - holocene_time: None, - batch_inbox_address: address!("ff00000000000000000000000000000000000010"), - deposit_contract_address: address!("beb5fc579115071764c7423a4f12edde41f106ed"), - l1_system_config_address: address!("229047fed2591dbec1ef1118d64f7af3db9eb290"), - protocol_versions_address: address!("8062abc286f5e7d9428a0ccb9abd71e50d93b935"), - superchain_config_address: Some(address!("95703e0982140D16f8ebA6d158FccEde42f04a4C")), - da_challenge_address: None, - blobs_enabled_l1_timestamp: None, -}; - -/// The [RollupConfig] for OP Sepolia. -pub const OP_SEPOLIA_CONFIG: RollupConfig = RollupConfig { - genesis: ChainGenesis { - l1: BlockID { - hash: b256!("48f520cf4ddaf34c8336e6e490632ea3cf1e5e93b0b2bc6e917557e31845371b"), - number: 4071408, - }, - l2: BlockID { - hash: b256!("102de6ffb001480cc9b8b548fd05c34cd4f46ae4aa91759393db90ea0409887d"), - number: 0, - }, - l2_time: 1691802540, - system_config: Some(SystemConfig { - batcher_address: address!("8f23bb38f531600e5d8fddaaec41f13fab46e98c"), - overhead: uint!(0xbc_U256), - scalar: uint!(0xa6fe0_U256), - gas_limit: 30_000_000, - base_fee_scalar: None, - blob_base_fee_scalar: None, - }), - extra_data: None, - }, - block_time: 2, - max_sequencer_drift: 600, - seq_window_size: 3600, - channel_timeout: 300, - granite_channel_timeout: 50, - l1_chain_id: 11155111, - l2_chain_id: 11155420, - base_fee_params: OP_SEPOLIA_BASE_FEE_PARAMS, - canyon_base_fee_params: Some(OP_SEPOLIA_CANYON_BASE_FEE_PARAMS), - regolith_time: Some(0), - canyon_time: Some(1699981200), - delta_time: Some(1703203200), - ecotone_time: Some(1708534800), - fjord_time: Some(1716998400), - granite_time: Some(1723478400), - holocene_time: None, - batch_inbox_address: address!("ff00000000000000000000000000000011155420"), - deposit_contract_address: address!("16fc5058f25648194471939df75cf27a2fdc48bc"), - l1_system_config_address: address!("034edd2a225f7f429a63e0f1d2084b9e0a93b538"), - protocol_versions_address: address!("79add5713b383daa0a138d3c4780c7a1804a8090"), - superchain_config_address: Some(address!("C2Be75506d5724086DEB7245bd260Cc9753911Be")), - da_challenge_address: None, - blobs_enabled_l1_timestamp: None, -}; - -/// The [RollupConfig] for Base Mainnet. -pub const BASE_MAINNET_CONFIG: RollupConfig = RollupConfig { - genesis: ChainGenesis { - l1: BlockID { - hash: b256!("5c13d307623a926cd31415036c8b7fa14572f9dac64528e857a470511fc30771"), - number: 17_481_768_u64, - }, - l2: BlockID { - hash: b256!("f712aa9241cc24369b143cf6dce85f0902a9731e70d66818a3a5845b296c73dd"), - number: 0_u64, - }, - l2_time: 1686789347_u64, - system_config: Some(SystemConfig { - batcher_address: address!("5050f69a9786f081509234f1a7f4684b5e5b76c9"), - overhead: uint!(0xbc_U256), - scalar: uint!(0xa6fe0_U256), - gas_limit: 30_000_000_u64, - base_fee_scalar: None, - blob_base_fee_scalar: None, - }), - extra_data: None, - }, - block_time: 2, - max_sequencer_drift: 600, - seq_window_size: 3600, - channel_timeout: 300, - granite_channel_timeout: 50, - l1_chain_id: 1, - l2_chain_id: 8453, - base_fee_params: OP_BASE_FEE_PARAMS, - canyon_base_fee_params: Some(OP_CANYON_BASE_FEE_PARAMS), - regolith_time: Some(0_u64), - canyon_time: Some(1704992401), - delta_time: Some(1708560000), - ecotone_time: Some(1710374401), - fjord_time: Some(1720627201), - granite_time: Some(1_726_070_401_u64), - holocene_time: None, - batch_inbox_address: address!("ff00000000000000000000000000000000008453"), - deposit_contract_address: address!("49048044d57e1c92a77f79988d21fa8faf74e97e"), - l1_system_config_address: address!("73a79fab69143498ed3712e519a88a918e1f4072"), - protocol_versions_address: address!("8062abc286f5e7d9428a0ccb9abd71e50d93b935"), - superchain_config_address: Some(address!("95703e0982140D16f8ebA6d158FccEde42f04a4C")), - da_challenge_address: None, - blobs_enabled_l1_timestamp: None, -}; - -/// The [RollupConfig] for Base Sepolia. -pub const BASE_SEPOLIA_CONFIG: RollupConfig = RollupConfig { - genesis: ChainGenesis { - l1: BlockID { - hash: b256!("cac9a83291d4dec146d6f7f69ab2304f23f5be87b1789119a0c5b1e4482444ed"), - number: 4370868, - }, - l2: BlockID { - hash: b256!("0dcc9e089e30b90ddfc55be9a37dd15bc551aeee999d2e2b51414c54eaf934e4"), - number: 0, - }, - l2_time: 1695768288, - system_config: Some(SystemConfig { - batcher_address: address!("6cdebe940bc0f26850285caca097c11c33103e47"), - overhead: uint!(0x834_U256), - scalar: uint!(0xf4240_U256), - gas_limit: 25000000, - base_fee_scalar: None, - blob_base_fee_scalar: None, - }), - extra_data: None, - }, - block_time: 2, - max_sequencer_drift: 600, - seq_window_size: 3600, - channel_timeout: 300, - granite_channel_timeout: 50, - l1_chain_id: 11155111, - l2_chain_id: 84532, - base_fee_params: BASE_SEPOLIA_BASE_FEE_PARAMS, - canyon_base_fee_params: Some(BASE_SEPOLIA_CANYON_BASE_FEE_PARAMS), - regolith_time: Some(0), - canyon_time: Some(1699981200), - delta_time: Some(1703203200), - ecotone_time: Some(1708534800), - fjord_time: Some(1716998400), - granite_time: Some(1723478400), - holocene_time: None, - batch_inbox_address: address!("ff00000000000000000000000000000000084532"), - deposit_contract_address: address!("49f53e41452c74589e85ca1677426ba426459e85"), - l1_system_config_address: address!("f272670eb55e895584501d564afeb048bed26194"), - protocol_versions_address: address!("79add5713b383daa0a138d3c4780c7a1804a8090"), - superchain_config_address: Some(address!("C2Be75506d5724086DEB7245bd260Cc9753911Be")), - da_challenge_address: None, - blobs_enabled_l1_timestamp: None, -}; - -#[cfg(test)] -mod tests { - use super::*; - - #[test] - fn test_regolith_active() { - let mut config = RollupConfig::default(); - assert!(!config.is_regolith_active(0)); - config.regolith_time = Some(10); - assert!(config.is_regolith_active(10)); - assert!(!config.is_regolith_active(9)); - } - - #[test] - fn test_canyon_active() { - let mut config = RollupConfig::default(); - assert!(!config.is_canyon_active(0)); - config.canyon_time = Some(10); - assert!(config.is_canyon_active(10)); - assert!(!config.is_canyon_active(9)); - } - - #[test] - fn test_delta_active() { - let mut config = RollupConfig::default(); - assert!(!config.is_delta_active(0)); - config.delta_time = Some(10); - assert!(config.is_delta_active(10)); - assert!(!config.is_delta_active(9)); - } - - #[test] - fn test_ecotone_active() { - let mut config = RollupConfig::default(); - assert!(!config.is_ecotone_active(0)); - config.ecotone_time = Some(10); - assert!(config.is_ecotone_active(10)); - assert!(!config.is_ecotone_active(9)); - } - - #[test] - fn test_fjord_active() { - let mut config = RollupConfig::default(); - assert!(!config.is_fjord_active(0)); - config.fjord_time = Some(10); - assert!(config.is_fjord_active(10)); - assert!(!config.is_fjord_active(9)); - } - - #[test] - fn test_granite_active() { - let mut config = RollupConfig::default(); - assert!(!config.is_granite_active(0)); - config.granite_time = Some(10); - assert!(config.is_granite_active(10)); - assert!(!config.is_granite_active(9)); - } - - #[test] - fn test_holocene_active() { - let mut config = RollupConfig::default(); - assert!(!config.is_holocene_active(0)); - config.holocene_time = Some(10); - assert!(config.is_holocene_active(10)); - assert!(!config.is_holocene_active(9)); - } - - #[test] - fn test_alt_da_enabled() { - let mut config = RollupConfig::default(); - assert!(!config.is_alt_da_enabled()); - config.da_challenge_address = Some(Address::ZERO); - assert!(!config.is_alt_da_enabled()); - config.da_challenge_address = Some(address!("0000000000000000000000000000000000000001")); - assert!(config.is_alt_da_enabled()); - } - - #[test] - fn test_granite_channel_timeout() { - let mut config = RollupConfig { - channel_timeout: 100, - granite_time: Some(10), - ..Default::default() - }; - assert_eq!(config.channel_timeout(0), 100); - assert_eq!(config.channel_timeout(10), GRANITE_CHANNEL_TIMEOUT); - config.granite_time = None; - assert_eq!(config.channel_timeout(10), 100); - } - - #[test] - fn test_max_sequencer_drift() { - let mut config = RollupConfig { - max_sequencer_drift: 100, - ..Default::default() - }; - assert_eq!(config.max_sequencer_drift(0), 100); - config.fjord_time = Some(10); - assert_eq!(config.max_sequencer_drift(0), 100); - assert_eq!(config.max_sequencer_drift(10), FJORD_MAX_SEQUENCER_DRIFT); - } -} diff --git a/bindings/rust-primitives/src/superchain.rs b/bindings/rust-primitives/src/superchain.rs deleted file mode 100644 index 157a06d99..000000000 --- a/bindings/rust-primitives/src/superchain.rs +++ /dev/null @@ -1,65 +0,0 @@ -//! Superchain types. - -use alloc::{string::String, vec::Vec}; -use alloy_primitives::Address; - -use crate::ChainConfig; -use crate::HardForkConfiguration; - -/// A superchain configuration. -#[derive(Debug, Clone, Default, Hash, Eq, PartialEq)] -#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -pub struct Superchain { - /// Superchain identifier, without capitalization or display changes. - pub name: String, - /// Superchain configuration file contents. - pub config: SuperchainConfig, - /// Chain IDs of chains that are part of this superchain. - pub chains: Vec, -} - -/// A superchain configuration file format -#[derive(Debug, Clone, Default, Hash, Eq, PartialEq)] -#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -pub struct SuperchainConfig { - /// Superchain name (e.g. "Mainnet") - pub name: String, - /// Superchain L1 anchor information - pub l1: SuperchainL1Info, - /// Optional addresses for the superchain-wide default protocol versions contract. - pub protocol_versions_addr: Option
, - /// Optional address for the superchain-wide default superchain config contract. - pub superchain_config_addr: Option
, - /// Hardfork Configuration. These values may be overridden by individual chains. - #[cfg_attr(feature = "serde", serde(flatten))] - pub hardfork_defaults: HardForkConfiguration, -} - -/// Superchain L1 anchor information -#[derive(Debug, Clone, Default, Hash, Eq, PartialEq)] -#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -pub struct SuperchainL1Info { - /// L1 chain ID - pub chain_id: u64, - /// L1 chain public RPC endpoint - pub public_rpc: String, - /// L1 chain explorer RPC endpoint - pub explorer: String, -} - -/// Level of integration with the superchain. -#[derive(Debug, Clone, Default, Hash, Eq, PartialEq)] -#[cfg_attr( - feature = "serde", - derive(serde_repr::Serialize_repr, serde_repr::Deserialize_repr) -)] -#[repr(u8)] -pub enum SuperchainLevel { - /// Frontier chains are chains with customizations beyond the - /// standard OP Stack configuration and are considered "advanced". - Frontier = 0, - /// Standard chains don't have any customizations beyond the - /// standard OP Stack configuration and are considered "vanilla". - #[default] - Standard = 1, -} diff --git a/bindings/rust-primitives/src/system_config.rs b/bindings/rust-primitives/src/system_config.rs deleted file mode 100644 index e2223e29c..000000000 --- a/bindings/rust-primitives/src/system_config.rs +++ /dev/null @@ -1,385 +0,0 @@ -//! System Config Type - -use crate::rollup_config::RollupConfig; -use alloy_consensus::{Eip658Value, Receipt}; -use alloy_primitives::{address, b256, Address, Log, B256, U256, U64}; -use alloy_sol_types::{sol, SolType}; -use anyhow::{anyhow, bail, Result}; - -/// `keccak256("ConfigUpdate(uint256,uint8,bytes)")` -pub const CONFIG_UPDATE_TOPIC: B256 = - b256!("1d2b0bda21d56b8bd12d4f94ebacffdfb35f5e226f84b461103bb8beab6353be"); - -/// The initial version of the system config event log. -pub const CONFIG_UPDATE_EVENT_VERSION_0: B256 = B256::ZERO; - -/// System configuration. -#[derive(Debug, Clone, Default, Hash, Eq, PartialEq)] -#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -#[cfg_attr(feature = "serde", serde(rename_all = "camelCase"))] -pub struct SystemConfig { - /// Batcher address - pub batcher_address: Address, - /// Fee overhead value - pub overhead: U256, - /// Fee scalar value - pub scalar: U256, - /// Gas limit value - pub gas_limit: u64, - /// Base fee scalar value - pub base_fee_scalar: Option, - /// Blob base fee scalar value - pub blob_base_fee_scalar: Option, -} - -/// Represents type of update to the system config. -#[derive(Debug, Clone, Copy, Hash, PartialEq, Eq)] -#[repr(u64)] -pub enum SystemConfigUpdateType { - /// Batcher update type - Batcher = 0, - /// Gas config update type - GasConfig = 1, - /// Gas limit update type - GasLimit = 2, - /// Unsafe block signer update type - UnsafeBlockSigner = 3, -} - -impl TryFrom for SystemConfigUpdateType { - type Error = anyhow::Error; - - fn try_from(value: u64) -> core::prelude::v1::Result { - match value { - 0 => Ok(SystemConfigUpdateType::Batcher), - 1 => Ok(SystemConfigUpdateType::GasConfig), - 2 => Ok(SystemConfigUpdateType::GasLimit), - 3 => Ok(SystemConfigUpdateType::UnsafeBlockSigner), - _ => bail!("Invalid SystemConfigUpdateType value: {}", value), - } - } -} - -impl SystemConfig { - /// Filters all L1 receipts to find config updates and applies the config updates. - pub fn update_with_receipts( - &mut self, - receipts: &[Receipt], - rollup_config: &RollupConfig, - l1_time: u64, - ) -> Result<()> { - for receipt in receipts { - if Eip658Value::Eip658(false) == receipt.status { - continue; - } - - receipt.logs.iter().try_for_each(|log| { - let topics = log.topics(); - if log.address == rollup_config.l1_system_config_address - && !topics.is_empty() - && topics[0] == CONFIG_UPDATE_TOPIC - { - if let Err(e) = self.process_config_update_log(log, rollup_config, l1_time) { - anyhow::bail!("Failed to process config update log: {:?}", e); - } - } - Ok::<(), anyhow::Error>(()) - })?; - } - Ok::<(), anyhow::Error>(()) - } - - /// Decodes an EVM log entry emitted by the system config contract and applies it as a - /// [SystemConfig] change. - /// - /// Parse log data for: - /// - /// ```text - /// event ConfigUpdate( - /// uint256 indexed version, - /// UpdateType indexed updateType, - /// bytes data - /// ); - /// ``` - fn process_config_update_log( - &mut self, - log: &Log, - rollup_config: &RollupConfig, - l1_time: u64, - ) -> Result<()> { - if log.topics().len() < 3 { - bail!("Invalid config update log: not enough topics"); - } - if log.topics()[0] != CONFIG_UPDATE_TOPIC { - bail!("Invalid config update log: invalid topic"); - } - - // Parse the config update log - let version = log.topics()[1]; - if version != CONFIG_UPDATE_EVENT_VERSION_0 { - bail!("Invalid config update log: unsupported version"); - } - let update_type = u64::from_be_bytes( - log.topics()[2].as_slice()[24..] - .try_into() - .map_err(|_| anyhow!("Failed to convert update type to u64"))?, - ); - let log_data = log.data.data.as_ref(); - - match update_type.try_into()? { - SystemConfigUpdateType::Batcher => { - if log_data.len() != 96 { - bail!("Invalid config update log: invalid data length"); - } - - let pointer = ::abi_decode(&log_data[0..32], true) - .map_err(|_| anyhow!("Failed to decode batcher update log"))?; - if pointer != 32 { - bail!("Invalid config update log: invalid data pointer"); - } - let length = ::abi_decode(&log_data[32..64], true) - .map_err(|_| anyhow!("Failed to decode batcher update log"))?; - if length != 32 { - bail!("Invalid config update log: invalid data length"); - } - - let batcher_address = - ::abi_decode(&log.data.data.as_ref()[64..], true) - .map_err(|_| anyhow!("Failed to decode batcher update log"))?; - self.batcher_address = batcher_address; - } - SystemConfigUpdateType::GasConfig => { - if log_data.len() != 128 { - bail!("Invalid config update log: invalid data length"); - } - - let pointer = ::abi_decode(&log_data[0..32], true) - .map_err(|_| anyhow!("Invalid config update log: invalid data pointer"))?; - if pointer != 32 { - bail!("Invalid config update log: invalid data pointer"); - } - let length = ::abi_decode(&log_data[32..64], true) - .map_err(|_| anyhow!("Invalid config update log: invalid data length"))?; - if length != 64 { - bail!("Invalid config update log: invalid data length"); - } - - let overhead = ::abi_decode(&log_data[64..96], true) - .map_err(|_| anyhow!("Invalid config update log: invalid overhead"))?; - let scalar = ::abi_decode(&log_data[96..], true) - .map_err(|_| anyhow!("Invalid config update log: invalid scalar"))?; - - if rollup_config.is_ecotone_active(l1_time) { - if RollupConfig::check_ecotone_l1_system_config_scalar(scalar.to_be_bytes()) - .is_err() - { - // ignore invalid scalars, retain the old system-config scalar - return Ok(()); - } - - // retain the scalar data in encoded form - self.scalar = scalar; - // zero out the overhead, it will not affect the state-transition after Ecotone - self.overhead = U256::ZERO; - } else { - self.scalar = scalar; - self.overhead = overhead; - } - } - SystemConfigUpdateType::GasLimit => { - if log_data.len() != 96 { - bail!("Invalid config update log: invalid data length"); - } - - let pointer = ::abi_decode(&log_data[0..32], true) - .map_err(|_| anyhow!("Invalid config update log: invalid data pointer"))?; - if pointer != 32 { - bail!("Invalid config update log: invalid data pointer"); - } - let length = ::abi_decode(&log_data[32..64], true) - .map_err(|_| anyhow!("Invalid config update log: invalid data length"))?; - if length != 32 { - bail!("Invalid config update log: invalid data length"); - } - - let gas_limit = ::abi_decode(&log_data[64..], true) - .map_err(|_| anyhow!("Invalid config update log: invalid gas limit"))?; - self.gas_limit = U64::from(gas_limit).saturating_to::(); - } - SystemConfigUpdateType::UnsafeBlockSigner => { - // Ignored in derivation - } - } - - Ok(()) - } -} - -/// System accounts -#[derive(Debug, Clone, Copy, PartialEq, Eq)] -#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] -pub struct SystemAccounts { - /// The address that can deposit attributes - pub attributes_depositor: Address, - /// The address of the attributes predeploy - pub attributes_predeploy: Address, - /// The address of the fee vault - pub fee_vault: Address, -} - -impl Default for SystemAccounts { - fn default() -> Self { - Self { - attributes_depositor: address!("deaddeaddeaddeaddeaddeaddeaddeaddead0001"), - attributes_predeploy: address!("4200000000000000000000000000000000000015"), - fee_vault: address!("4200000000000000000000000000000000000011"), - } - } -} - -#[cfg(test)] -mod test { - use super::*; - use crate::ChainGenesis; - use alloc::vec; - use alloy_primitives::{b256, hex, LogData, B256}; - - fn mock_rollup_config(system_config: SystemConfig) -> RollupConfig { - RollupConfig { - genesis: ChainGenesis { - system_config: Some(system_config), - ..Default::default() - }, - block_time: 2, - l1_chain_id: 1, - l2_chain_id: 10, - regolith_time: Some(0), - canyon_time: Some(0), - delta_time: Some(0), - ecotone_time: Some(10), - fjord_time: Some(0), - granite_time: Some(0), - holocene_time: Some(0), - blobs_enabled_l1_timestamp: Some(0), - da_challenge_address: Some(Address::ZERO), - ..Default::default() - } - } - - #[test] - fn test_system_config_update_batcher_log() { - const UPDATE_TYPE: B256 = - b256!("0000000000000000000000000000000000000000000000000000000000000000"); - - let mut system_config = SystemConfig::default(); - let rollup_config = mock_rollup_config(system_config.clone()); - - let update_log = Log { - address: Address::ZERO, - data: LogData::new_unchecked( - vec![ - CONFIG_UPDATE_TOPIC, - CONFIG_UPDATE_EVENT_VERSION_0, - UPDATE_TYPE, - ], - hex!("00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000beef").into() - ) - }; - - // Update the batcher address. - system_config - .process_config_update_log(&update_log, &rollup_config, 0) - .unwrap(); - - assert_eq!( - system_config.batcher_address, - address!("000000000000000000000000000000000000bEEF") - ); - } - - #[test] - fn test_system_config_update_gas_config_log() { - const UPDATE_TYPE: B256 = - b256!("0000000000000000000000000000000000000000000000000000000000000001"); - - let mut system_config = SystemConfig::default(); - let rollup_config = mock_rollup_config(system_config.clone()); - - let update_log = Log { - address: Address::ZERO, - data: LogData::new_unchecked( - vec![ - CONFIG_UPDATE_TOPIC, - CONFIG_UPDATE_EVENT_VERSION_0, - UPDATE_TYPE, - ], - hex!("00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000babe000000000000000000000000000000000000000000000000000000000000beef").into() - ) - }; - - // Update the batcher address. - system_config - .process_config_update_log(&update_log, &rollup_config, 0) - .unwrap(); - - assert_eq!(system_config.overhead, U256::from(0xbabe)); - assert_eq!(system_config.scalar, U256::from(0xbeef)); - } - - #[test] - fn test_system_config_update_gas_config_log_ecotone() { - const UPDATE_TYPE: B256 = - b256!("0000000000000000000000000000000000000000000000000000000000000001"); - - let mut system_config = SystemConfig::default(); - let rollup_config = mock_rollup_config(system_config.clone()); - - let update_log = Log { - address: Address::ZERO, - data: LogData::new_unchecked( - vec![ - CONFIG_UPDATE_TOPIC, - CONFIG_UPDATE_EVENT_VERSION_0, - UPDATE_TYPE, - ], - hex!("00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000babe000000000000000000000000000000000000000000000000000000000000beef").into() - ) - }; - - // Update the batcher address. - system_config - .process_config_update_log(&update_log, &rollup_config, 10) - .unwrap(); - - assert_eq!(system_config.overhead, U256::from(0)); - assert_eq!(system_config.scalar, U256::from(0xbeef)); - } - - #[test] - fn test_system_config_update_gas_limit_log() { - const UPDATE_TYPE: B256 = - b256!("0000000000000000000000000000000000000000000000000000000000000002"); - - let mut system_config = SystemConfig::default(); - let rollup_config = mock_rollup_config(system_config.clone()); - - let update_log = Log { - address: Address::ZERO, - data: LogData::new_unchecked( - vec![ - CONFIG_UPDATE_TOPIC, - CONFIG_UPDATE_EVENT_VERSION_0, - UPDATE_TYPE, - ], - hex!("00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000beef").into() - ) - }; - - // Update the batcher address. - system_config - .process_config_update_log(&update_log, &rollup_config, 0) - .unwrap(); - - assert_eq!(system_config.gas_limit, 0xbeef_u64); - } -} diff --git a/bindings/superchain/Cargo.lock b/bindings/superchain/Cargo.lock deleted file mode 100644 index 24ce6ab29..000000000 --- a/bindings/superchain/Cargo.lock +++ /dev/null @@ -1,863 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "ahash" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" -dependencies = [ - "cfg-if", - "once_cell", - "version_check", - "zerocopy", -] - -[[package]] -name = "allocator-api2" -version = "0.2.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c6cb57a04249c6480766f7f7cef5467412af1490f8d1e243141daddada3264f" - -[[package]] -name = "alloy-consensus" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04c309895995eaa4bfcc345f5515a39c7df9447798645cc8bf462b6c5bf1dc96" -dependencies = [ - "alloy-eips", - "alloy-primitives", - "alloy-rlp", - "alloy-serde", - "serde", -] - -[[package]] -name = "alloy-eips" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9431c99a3b3fe606ede4b3d4043bdfbcb780c45b8d8d226c3804e2b75cfbe68" -dependencies = [ - "alloy-primitives", - "alloy-rlp", - "alloy-serde", - "c-kzg", - "serde", - "sha2", -] - -[[package]] -name = "alloy-genesis" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79614dfe86144328da11098edcc7bc1a3f25ad8d3134a9eb9e857e06f0d9840d" -dependencies = [ - "alloy-primitives", - "alloy-serde", - "serde", -] - -[[package]] -name = "alloy-primitives" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccb3ead547f4532bc8af961649942f0b9c16ee9226e26caa3f38420651cc0bf4" -dependencies = [ - "alloy-rlp", - "bytes", - "cfg-if", - "const-hex", - "derive_more", - "hex-literal", - "itoa", - "ruint", - "serde", - "tiny-keccak", -] - -[[package]] -name = "alloy-rlp" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26154390b1d205a4a7ac7352aa2eb4f81f391399d4e2f546fb81a2f8bb383f62" -dependencies = [ - "alloy-rlp-derive", - "bytes", -] - -[[package]] -name = "alloy-rlp-derive" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d0f2d905ebd295e7effec65e5f6868d153936130ae718352771de3e7d03c75c" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.76", -] - -[[package]] -name = "alloy-serde" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e33feda6a53e6079895aed1d08dcb98a1377b000d80d16370fbbdb8155d547ef" -dependencies = [ - "alloy-primitives", - "serde", - "serde_json", -] - -[[package]] -name = "alloy-sol-macro" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b40397ddcdcc266f59f959770f601ce1280e699a91fc1862f29cef91707cd09" -dependencies = [ - "alloy-sol-macro-expander", - "alloy-sol-macro-input", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 2.0.76", -] - -[[package]] -name = "alloy-sol-macro-expander" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "867a5469d61480fea08c7333ffeca52d5b621f5ca2e44f271b117ec1fc9a0525" -dependencies = [ - "alloy-sol-macro-input", - "const-hex", - "heck", - "indexmap", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 2.0.76", - "syn-solidity", - "tiny-keccak", -] - -[[package]] -name = "alloy-sol-macro-input" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e482dc33a32b6fadbc0f599adea520bd3aaa585c141a80b404d0a3e3fa72528" -dependencies = [ - "const-hex", - "dunce", - "heck", - "proc-macro2", - "quote", - "syn 2.0.76", - "syn-solidity", -] - -[[package]] -name = "alloy-sol-types" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a91ca40fa20793ae9c3841b83e74569d1cc9af29a2f5237314fd3452d51e38c7" -dependencies = [ - "alloy-primitives", - "alloy-sol-macro", - "const-hex", -] - -[[package]] -name = "anyhow" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" - -[[package]] -name = "autocfg" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" - -[[package]] -name = "bitflags" -version = "2.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "blst" -version = "0.3.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4378725facc195f1a538864863f6de233b500a8862747e7f165078a419d5e874" -dependencies = [ - "cc", - "glob", - "threadpool", - "zeroize", -] - -[[package]] -name = "byteorder" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" - -[[package]] -name = "bytes" -version = "1.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8318a53db07bb3f8dca91a600466bdb3f2eaadeedfdbcf02e1accbad9271ba50" -dependencies = [ - "serde", -] - -[[package]] -name = "c-kzg" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0307f72feab3300336fb803a57134159f6e20139af1357f36c54cb90d8e8928" -dependencies = [ - "blst", - "cc", - "glob", - "hex", - "libc", - "serde", -] - -[[package]] -name = "cc" -version = "1.1.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57b6a275aa2903740dc87da01c62040406b8812552e97129a63ea8850a17c6e6" -dependencies = [ - "shlex", -] - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "const-hex" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8a24a26d37e1ffd45343323dc9fe6654ceea44c12f2fcb3d7ac29e610bc6" -dependencies = [ - "cfg-if", - "cpufeatures", - "hex", - "proptest", - "serde", -] - -[[package]] -name = "convert_case" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" - -[[package]] -name = "cpufeatures" -version = "0.2.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51e852e6dc9a5bed1fae92dd2375037bf2b768725bf3be87811edee3249d09ad" -dependencies = [ - "libc", -] - -[[package]] -name = "crunchy" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "derive_more" -version = "0.99.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f33878137e4dafd7fa914ad4e259e18a4e8e532b9617a2d0150262bf53abfce" -dependencies = [ - "convert_case", - "proc-macro2", - "quote", - "rustc_version", - "syn 2.0.76", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer", - "crypto-common", -] - -[[package]] -name = "dunce" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813" - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "glob" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" - -[[package]] -name = "hashbrown" -version = "0.14.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" -dependencies = [ - "ahash", - "allocator-api2", - "serde", -] - -[[package]] -name = "heck" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" - -[[package]] -name = "hermit-abi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" -dependencies = [ - "serde", -] - -[[package]] -name = "hex-literal" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" - -[[package]] -name = "indexmap" -version = "2.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93ead53efc7ea8ed3cfb0c79fc8023fbb782a5432b52830b6518941cebe6505c" -dependencies = [ - "equivalent", - "hashbrown", -] - -[[package]] -name = "itoa" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" - -[[package]] -name = "lazy_static" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" - -[[package]] -name = "libc" -version = "0.2.158" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8adc4bb1803a324070e64a98ae98f38934d91957a99cfb3a43dcbc01bc56439" - -[[package]] -name = "libm" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" - -[[package]] -name = "memchr" -version = "2.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" - -[[package]] -name = "num-traits" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" -dependencies = [ - "autocfg", - "libm", -] - -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi", - "libc", -] - -[[package]] -name = "once_cell" -version = "1.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" - -[[package]] -name = "paste" -version = "1.0.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" - -[[package]] -name = "ppv-lite86" -version = "0.2.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04" -dependencies = [ - "zerocopy", -] - -[[package]] -name = "proc-macro-error" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" -dependencies = [ - "proc-macro-error-attr", - "proc-macro2", - "quote", - "syn 1.0.109", - "version_check", -] - -[[package]] -name = "proc-macro-error-attr" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" -dependencies = [ - "proc-macro2", - "quote", - "version_check", -] - -[[package]] -name = "proc-macro2" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "proptest" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4c2511913b88df1637da85cc8d96ec8e43a3f8bb8ccb71ee1ac240d6f3df58d" -dependencies = [ - "bitflags", - "num-traits", - "rand", - "rand_chacha", - "rand_xorshift", - "unarray", -] - -[[package]] -name = "quote" -version = "1.0.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5b9d34b8991d19d98081b46eacdd8eb58c6f2b201139f7c5f643cc155a633af" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "rand_core", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" - -[[package]] -name = "rand_xorshift" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f" -dependencies = [ - "rand_core", -] - -[[package]] -name = "ruint" -version = "1.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c3cc4c2511671f327125da14133d0c5c5d137f006a1017a16f557bc85b16286" -dependencies = [ - "alloy-rlp", - "proptest", - "rand", - "ruint-macro", - "serde", - "valuable", - "zeroize", -] - -[[package]] -name = "ruint-macro" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48fd7bd8a6377e15ad9d42a8ec25371b94ddc67abe7c8b9127bec79bebaaae18" - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "ryu" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" - -[[package]] -name = "semver" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" - -[[package]] -name = "serde" -version = "1.0.209" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99fce0ffe7310761ca6bf9faf5115afbc19688edd00171d81b1bb1b116c63e09" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.209" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5831b979fd7b5439637af1752d535ff49f4860c0f341d1baeb6faf0f4242170" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.76", -] - -[[package]] -name = "serde_json" -version = "1.0.127" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8043c06d9f82bd7271361ed64f415fe5e12a77fdb52e573e7f06a516dea329ad" -dependencies = [ - "itoa", - "memchr", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.76", -] - -[[package]] -name = "serde_spanned" -version = "0.6.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb5b1b31579f3811bf615c144393417496f152e12ac8b7663bf664f4a815306d" -dependencies = [ - "serde", -] - -[[package]] -name = "sha2" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest", -] - -[[package]] -name = "shlex" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" - -[[package]] -name = "superchain" -version = "0.1.1" -dependencies = [ - "superchain-primitives", - "superchain-registry", -] - -[[package]] -name = "superchain-primitives" -version = "0.2.2" -dependencies = [ - "alloy-consensus", - "alloy-eips", - "alloy-genesis", - "alloy-primitives", - "alloy-sol-types", - "anyhow", - "serde", - "serde_repr", -] - -[[package]] -name = "superchain-registry" -version = "0.2.6" -dependencies = [ - "hashbrown", - "lazy_static", - "serde", - "superchain-primitives", - "toml", -] - -[[package]] -name = "syn" -version = "1.0.109" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" -dependencies = [ - "proc-macro2", - "unicode-ident", -] - -[[package]] -name = "syn" -version = "2.0.76" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "578e081a14e0cefc3279b0472138c513f37b41a08d5a3cca9b6e4e8ceb6cd525" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "syn-solidity" -version = "0.7.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c837dc8852cb7074e46b444afb81783140dab12c58867b49fb3898fbafedf7ea" -dependencies = [ - "paste", - "proc-macro2", - "quote", - "syn 2.0.76", -] - -[[package]] -name = "threadpool" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d050e60b33d41c19108b32cea32164033a9013fe3b46cbd4457559bfbf77afaa" -dependencies = [ - "num_cpus", -] - -[[package]] -name = "tiny-keccak" -version = "2.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c9d3793400a45f954c52e73d068316d76b6f4e36977e3fcebb13a2721e80237" -dependencies = [ - "crunchy", -] - -[[package]] -name = "toml" -version = "0.8.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1ed1f98e3fdc28d6d910e6737ae6ab1a93bf1985935a1193e68f93eeb68d24e" -dependencies = [ - "serde", - "serde_spanned", - "toml_datetime", - "toml_edit", -] - -[[package]] -name = "toml_datetime" -version = "0.6.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0dd7358ecb8fc2f8d014bf86f6f638ce72ba252a2c3a2572f2a795f1d23efb41" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_edit" -version = "0.22.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "583c44c02ad26b0c3f3066fe629275e50627026c51ac2e595cca4c230ce1ce1d" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "winnow", -] - -[[package]] -name = "typenum" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" - -[[package]] -name = "unarray" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" - -[[package]] -name = "unicode-ident" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" - -[[package]] -name = "valuable" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" - -[[package]] -name = "version_check" -version = "0.9.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" - -[[package]] -name = "winnow" -version = "0.6.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68a9bda4691f099d435ad181000724da8e5899daa10713c2d432552b9ccd3a6f" -dependencies = [ - "memchr", -] - -[[package]] -name = "zerocopy" -version = "0.7.35" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0" -dependencies = [ - "byteorder", - "zerocopy-derive", -] - -[[package]] -name = "zerocopy-derive" -version = "0.7.35" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.76", -] - -[[package]] -name = "zeroize" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.76", -] diff --git a/bindings/superchain/Cargo.toml b/bindings/superchain/Cargo.toml deleted file mode 100644 index 59caef962..000000000 --- a/bindings/superchain/Cargo.toml +++ /dev/null @@ -1,35 +0,0 @@ -[package] -name = "superchain" -description = "The Superchain Registry" -version = "0.1.1" -edition = "2021" -license = "MIT" -authors = ["OP Contributors"] -repository = "https://github.com/ethereum-optimism/superchain-registry" -homepage = "https://github.com/ethereum-optimism/superchain-registry/bindings/superchain" - -[package.metadata.docs.rs] -all-features = true -rustdoc-args = ["--cfg", "docsrs"] - -[dependencies] -superchain-primitives = { path = "../rust-primitives", version = "0.2.2", default-features = false } - -# `serde` is optional, but enabled by default -# Since superchain-registry requires `serde`, we mark it as optional -superchain-registry = { path = "../rust-bindings", version = "0.2.6", optional = true, default-features = false } - -[features] -default = ["serde", "std"] - -serde = [ - "dep:superchain-registry", - "superchain-primitives/serde", -] - -std = [ - "serde", - "dep:superchain-registry", - "superchain-registry/std", - "superchain-primitives/std", -] diff --git a/bindings/superchain/Justfile b/bindings/superchain/Justfile deleted file mode 100644 index bd92ae78f..000000000 --- a/bindings/superchain/Justfile +++ /dev/null @@ -1,61 +0,0 @@ -set positional-arguments -alias t := tests -alias l := lint -alias f := fmt -alias b := build - -# default recipe to display help information -default: - @just --list - -# Runs everything needed for ci -ci: fmt lint tests - -# Run all tests -tests: test test-features test-docs - -# Formats -fmt: fmt-fix fmt-check - -# Lint the workspace for all available targets -lint: lint-source lint-source-features lint-docs - -# Build for the native target -build *args='': - cargo build --workspace --all $@ - -# Fixes the formatting -fmt-fix: - cargo +nightly fmt --all - -# Check the formatting -fmt-check: - cargo +nightly fmt --all -- --check - -# Lint the workspace -lint-source: fmt-check - cargo +nightly clippy --all --all-targets -- -D warnings - -# Lint the workspace -lint-source-features: fmt-check - cargo +nightly clippy --all --all-features --all-targets -- -D warnings - -# Lint the Rust documentation -lint-docs: - RUSTDOCFLAGS="-D warnings" cargo doc --all --no-deps --document-private-items - -# Test without features -test *args='': - cargo nextest run --all $@ - -# Test for the native target with all features -test-features *args='': - cargo nextest run --all --all-features $@ - -# Test the Rust documentation -test-docs: - cargo test --doc --all --locked - -# Release the crate -release: - cargo release publish --execute --no-confirm diff --git a/bindings/superchain/README.md b/bindings/superchain/README.md deleted file mode 100644 index 0f7327cf4..000000000 --- a/bindings/superchain/README.md +++ /dev/null @@ -1,69 +0,0 @@ -# `superchain` - -The `superchain` is an optionally `no_std` crate that provides core types -and bindings for the Superchain. - -It re-exports two crates: -- [`superchain-primitives`][scp] -- [`superchain-registry`][scr] _Only available if `serde` feature flag is enabled_ - -[`superchain-primitives`][scp] defines core types used in the `superchain-registry` -along with a few default values for core chains. - -[`superchain-registry`][scr] provides bindings to all chains in the `superchain`. - -## Usage - -Add the following to your `Cargo.toml`. - -```toml -[dependencies] -superchain = "0.1" -``` - -To make make `superchain` `no_std`, toggle `default-features` off like so. - -```toml -[dependencies] -superchain = { version = "0.1", default-features = false } -``` - -## Example - -[`superchain-registry`][scr] exposes lazily defined mappings from chain id -to chain configurations that the [`superchain`][sup] re-exports. Below -demonstrates getting the `RollupConfig` for OP Mainnet (Chain ID `10`). - -```rust -use superchain::ROLLUP_CONFIGS; - -let op_chain_id = 10; -let op_rollup_config = ROLLUP_CONFIGS.get(&op_chain_id); -println!("OP Mainnet Rollup Config: {:?}", op_rollup_config); -``` - -A mapping from chain id to `ChainConfig` is also available. - -```rust -use superchain::OPCHAINS; - -let op_chain_id = 10; -let op_chain_config = OPCHAINS.get(&op_chain_id); -println!("OP Mainnet Chain Config: {:?}", op_chain_config); -``` - -## Feature Flags - -- `serde`: Enables [`serde`][s] support for types and makes [`superchain-registry`][scr] types available. -- `std`: Uses the standard library to pull in environment variables. - - - -[sp]: ../rust-primitives - -[s]: https://crates.io/crates/serde -[sr]: https://github.com/ethereum-optimism/superchain-registry -[scr]: https://crates.io/crates/superchain-registry -[sup]: https://crates.io/crates/superchain -[scp]: https://crates.io/crates/superchain-primitives - diff --git a/bindings/superchain/src/lib.rs b/bindings/superchain/src/lib.rs deleted file mode 100644 index d4a1f6006..000000000 --- a/bindings/superchain/src/lib.rs +++ /dev/null @@ -1,18 +0,0 @@ -#![doc = include_str!("../README.md")] -#![warn(missing_debug_implementations, missing_docs, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] -#![cfg_attr(not(feature = "std"), no_std)] -#![cfg_attr(not(test), warn(unused_crate_dependencies))] - -/// Re-export types from [superchain_primitives]. -pub use superchain_primitives::*; - -/// Re-export [superchain_registry]. -#[cfg(feature = "serde")] -pub use superchain_registry; - -#[cfg(feature = "serde")] -pub use superchain_registry::{ - Chain, ChainList, HashMap, Registry, CHAINS, OPCHAINS, ROLLUP_CONFIGS, -}; diff --git a/docs/bindings.md b/docs/bindings.md deleted file mode 100644 index 21fb40f93..000000000 --- a/docs/bindings.md +++ /dev/null @@ -1,116 +0,0 @@ -# Bindings - -Bindings bridge the `superchain-registry` to other languages with associated types. - -## Rust Bindings - -There are two rust [crates](crates.io) that expose rust bindings. -- [`bindings/rust-primitives`][rp] -- [`bindings/rust-bindings`][rb] - -### Rust Primitives - -[`bindings/rust-primitives`][rp] contains rust types for the objects defined in the `superchain-registry`. -The `rust-primitives` directory is a `no_std` [crate][rpc] called [`superchain-primitives`][sp]. -It defines the `std` and `serde` feature flags that enable `std` library use and `serde` serialization -and deserialization support, respectively. Enabling these feature flags on the crate are as simple as -adding the `features` key to the dependency declaration. For example, in a project's `Cargo.toml`, to -use the `superchain-primitives` crate with `serde` support, add the following to the `[dependencies]` -section. - -```toml -# By default, superchain-primitives enables the `std` and `serde` feature flags. -superchain-primitives = { version = "0.2", features = [ "serde" ], default-features = false } -``` - -[`superchain-primitives`][sp] has minimal dependencies itself and uses [alloy][alloy] Ethereum -types internally. Below provides a breakdown of some core types defined in [`superchain-primitives`][sp]. - -**`ChainConfig`** - -The [`ChainConfig`][cc] is the chain configuration that is output from the `add-chain` command in the -`superchain-registry`. It contains genesis data, addresses for the onchain system config, hardfork -timestamps, rpc information, and other superchain-specific information. Static chain config files -are defined in [../superchain/configs/](../superchain/configs/). - -**`RollupConfig`** - -The [`RollupConfig`][rc], often confused with the `ChainConfig`, defines the configuration for -a rollup node. The [`RollupConfig`][rc] defines the parameters used for deriving the L2 chain as -well as batch-posting data on the flip side. It effectively defines the rules for the chain used by -consensus and execution clients. (e.g. `op-node`, `op-reth`, `op-geth`, ...) - -[`superchain-primitives`][sp] also exposes a few default `RollupConfig`s for convenience, providing an alternative to depending on [`superchain-registry`][sr] with `serde` required. - -**`Superchain`** - -[`Superchain`][s] defines a superchain for a given L1 network. It holds metadata such as the -name of the superchain, the L1 anchor information (chain id, rpc, explorer), and default -hardfork configuration values. Within the [`Superchain`][s], there's a list of [`ChainConfig`][cc]s -that belong to this superchain. - -### Rust Bindings - -[`bindings/rust-bindings`][rb] exports rust type definitions for chains in the `superchain-registry`. -The `rust-bindings` directory is a `no_std` [crate][rbc] called [`superchain-registry`][sr]. -It requires `serde` and enables `serde` features on dependencies including [`superchain-primitives`][sp], -which it depends on for types. To use the `superchain-regsitry` crate, add the crate as a dependency to -a `Cargo.toml`. - -```toml -# By default, superchain-registry enables the `std` feature, disabling `no_std`. -superchain-registry = { version = "0.2", default-features = false } -``` - -[`superchain-registry`][sr] declares lazy evaluated statics that expose `ChainConfig`s, `RollupConfig`s, -and `Chain` objects for all chains with static definitions in the superchain registry. The way this works -is the the golang side of the superchain registry contains an "internal code generation" script that has -been modified to output configuration files to the [`bindings/rust-bindings`][rb] directory in the `etc` -folder that are read by the [`superchain-registry`][sr] rust crate. These static config files contain -an up-to-date list of all superchain configurations with their chain configs. - -There are three core statics exposed by the [`superchain-registry`][sr]. -- `CHAINS`: A list of chain objects containing the superchain metadata for this chain. -- `OPCHAINS`: A map from chain id to `ChainConfig`. -- `ROLLUP_CONFIGS`: A map from chain id to `RollupConfig`. - -Where the [`superchain-primitives`][sp] crate contains a few hardcoded `RollupConfig` objects, the -[`superchain-registry`][sr] exports the _complete_ list of superchains and their chain's `RollupConfig`s -and `ChainConfig`s, at the expense of requiring `serde`. - -[`CHAINS`][chains], [`OPCHAINS`][opchains], and [`ROLLUP_CONFIGS`][rollups] are exported at the top-level -of the [`superchain-primitives`][sp] crate and can be used directly. For example, to get the rollup -config for OP Mainnet, one can use the [`ROLLUP_CONFIGS`][rollups] map to get the `RollupConfig` object. - -```rust -use superchain_registry::ROLLUP_CONFIGS; - -let op_chain_id = 10; -let op_mainnet_rcfg: &RollupConfig = ROLLUP_CONFIGS.get(&op_chain_id).unwrap(); -assert_eq!(op_mainnet_rcfg.chain_id, op_chain_id); -``` - -# Acknowledgements - -[Alloy][alloy] for creating and maintaining high quality Ethereum types in rust. - - - - -[rbc]: ../bindings/rust-bindings/Cargo.toml -[rb]: ../bindings/rust-bindings/ -[rpc]: ../bindings/rust-primitives/Cargo.toml -[rp]: ../bindings/rust-primitives/ - -[alloy]: https://github.com/alloy-rs/alloy - -[sr]: https://crates.io/crates/superchain-registry -[sp]: https://crates.io/crates/superchain-primitives - -[chains]: https://docs.rs/superchain-registry/latest/superchain_registry/struct.CHAINS.html -[opchains]: https://docs.rs/superchain-registry/latest/superchain_registry/struct.OPCHAINS.html -[rollups]: https://docs.rs/superchain-registry/latest/superchain_registry/struct.ROLLUP_CONFIGS.html - -[s]: https://docs.rs/superchain-primitives/latest/superchain_primitives/superchain/struct.Superchain.html -[cc]: https://docs.rs/superchain-primitives/latest/superchain_primitives/chain_config/struct.ChainConfig.html -[rc]: https://docs.rs/superchain-primitives/latest/superchain_primitives/rollup_config/struct.RollupConfig.html diff --git a/justfile b/justfile index 46186d2bb..a0171b29c 100644 --- a/justfile +++ b/justfile @@ -1,8 +1,6 @@ set positional-arguments -alias ct := cargo-tests -alias cl := cargo-lint -alias cf := cargo-format -alias cb := cargo-build +alias t := test-all +alias l := lint-all # Adding a chain add-chain: @@ -80,33 +78,3 @@ remove-chain SUPERCHAIN_TARGET CHAIN: rm superchain/configs/{{SUPERCHAIN_TARGET}}/{{CHAIN}}.toml rm superchain/extra/genesis/{{SUPERCHAIN_TARGET}}/{{CHAIN}}.json.gz just codegen - -# Run cargo tests -cargo-tests: - just bindings/rust-primitives/tests - just bindings/rust-bindings/tests - just bindings/superchain/tests - -# Run cargo format -cargo-format: - just bindings/rust-primitives/fmt - just bindings/rust-bindings/fmt - just bindings/superchain/fmt - -# Run cargo lints -cargo-lint: - just bindings/rust-primitives/lint - just bindings/rust-bindings/lint - just bindings/superchain/lint - -# Cargo build -cargo-build: - just bindings/rust-primitives/build - just bindings/rust-bindings/build - just bindings/superchain/build - -# Release -release: - just bindings/rust-primitives/release - just bindings/rust-bindings/release - just bindings/superchain/release diff --git a/superchain/configs/configs.toml b/superchain/configs/configs.toml new file mode 100644 index 000000000..843a49c18 --- /dev/null +++ b/superchain/configs/configs.toml @@ -0,0 +1,1088 @@ +############################################## +# DO NOT EDIT - THIS FILE IS AUTOGENERATED # +# DO NOT REMOVE - USED BY BINDINGS # +############################################## + +[[superchains]] + name = "mainnet" + [superchains.config] + name = "Mainnet" + protocol_versions_addr = "0x8062AbC286f5e7D9428a0Ccb9AbD71e50d93b935" + superchain_config_addr = "0x95703e0982140D16f8ebA6d158FccEde42f04a4C" + [superchains.config.l1] + chain_id = 1 + public_rpc = "https://ethereum-rpc.publicnode.com" + explorer = "https://etherscan.io" + + [[superchains.chains]] + name = "OP Mainnet" + chain_id = 10 + public_rpc = "https://mainnet.optimism.io" + sequencer_rpc = "https://mainnet-sequencer.optimism.io" + explorer = "https://explorer.optimism.io" + superchain_level = 1 + superchain_time = 0 + batch_inbox_addr = "0xFF00000000000000000000000000000000000010" + canyon_time = 1704992401 + delta_time = 1708560000 + ecotone_time = 1710374401 + fjord_time = 1720627201 + granite_time = 1726070401 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1686068903 + [superchains.chains.genesis.l1] + hash = "0x438335a20d98863a4c0c97999eb2481921ccd28553eac6f913af7c12aec04108" + number = 17422590 + [superchains.chains.genesis.l2] + hash = "0xdbf6a80fef073de06add9b0d14026d6e5a86c85f6d102c36d3d8e9cf89c2afd3" + number = 105235063 + [superchains.chains.genesis.system_config] + batcherAddress = "0x6887246668a3b87F54DeB3b94Ba47a6f63F32985" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0x847B5c174615B1B7fDF770882256e2D3E95b9D92" + ProxyAdminOwner = "0x5a0Aae59D09fccBdDb6C6CcEB07B7279367C3d2A" + Guardian = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" + Challenger = "0x9BA6e03D8B90dE867373Db8cF1A58d2F7F006b3A" + Proposer = "0x473300df21D047806A082244b417f96b32f13A33" + UnsafeBlockSigner = "0xAAAA45d9549EDA09E70937013520214382Ffc4A2" + BatchSubmitter = "0x6887246668a3b87F54DeB3b94Ba47a6f63F32985" + AddressManager = "0xdE1FCfB0851916CA5101820A69b13a4E276bd81F" + L1CrossDomainMessengerProxy = "0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1" + L1ERC721BridgeProxy = "0x5a7749f83b81B301cAb5f48EB8516B986DAef23D" + L1StandardBridgeProxy = "0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1" + L2OutputOracleProxy = "0x0000000000000000000000000000000000000000" + OptimismMintableERC20FactoryProxy = "0x75505a97BD334E7BD3C476893285569C4136Fa0F" + OptimismPortalProxy = "0xbEb5Fc579115071764c7423A4f12eDde41f106Ed" + SystemConfigProxy = "0x229047fed2591dbec1eF1118d64F7aF3dB9EB290" + ProxyAdmin = "0x543bA4AADBAb8f9025686Bd03993043599c6fB04" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x18DAc71c228D1C32c99489B7323d441E1175e443" + DelayedWETHProxy = "0xE497B094d6DbB3D5E4CaAc9a14696D7572588d14" + DisputeGameFactoryProxy = "0xe5965Ab5962eDc7477C8520243A95517CD252fA9" + FaultDisputeGame = "0x4146DF64D83acB0DcB0c1a4884a16f090165e122" + MIPS = "0x0f8EdFbDdD3c0256A80AD8C0F2560B1807873C9c" + PermissionedDisputeGame = "0xE9daD167EF4DE8812C1abD013Ac9570C616599A0" + PreimageOracle = "0xD326E10B8186e90F4E2adc5c13a2d0C137ee8b34" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "Orderly Mainnet" + chain_id = 291 + public_rpc = "https://rpc.orderly.network" + sequencer_rpc = "https://rpc.orderly.network" + explorer = "https://explorer.orderly.network" + superchain_level = 0 + superchain_time = 0 + batch_inbox_addr = "0x08aA34cC843CeEBcC88A627F18430294aA9780be" + canyon_time = 1704992401 + delta_time = 1708560000 + ecotone_time = 1710374401 + fjord_time = 1720627201 + granite_time = 1726070401 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1696608227 + [superchains.chains.genesis.l1] + hash = "0x787d5dd296d63bc6e7a4158d4f109e1260740ee115f5ed5124b35dece1fa3968" + number = 18292529 + [superchains.chains.genesis.l2] + hash = "0xe53c94ddd42714239429bd132ba2fa080c7e5cc7dca816ec6e482ec0418e6d7f" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0xf8dB8Aba597fF36cCD16fECfbb1B816B3236E9b8" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" + ProxyAdminOwner = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" + Guardian = "0xcE10372313Ca39Fbf75A09e7f4c0E57F070259f4" + Challenger = "0xcE10372313Ca39Fbf75A09e7f4c0E57F070259f4" + Proposer = "0x74BaD482a7f73C8286F50D8Aa03e53b7d24A5f3B" + UnsafeBlockSigner = "0xceED24B1Fd4A4393f6A9D2B137D9597dd5482569" + BatchSubmitter = "0xf8dB8Aba597fF36cCD16fECfbb1B816B3236E9b8" + AddressManager = "0x87630a802a3789463eC4b00f89b27b1e9f6b92e9" + L1CrossDomainMessengerProxy = "0xc76543A64666d9a073FaEF4e75F651c88e7DBC08" + L1ERC721BridgeProxy = "0x934Ab59Ef14b638653b1C0FEf7aB9a72186393DC" + L1StandardBridgeProxy = "0xe07eA0436100918F157DF35D01dCE5c11b16D1F1" + L2OutputOracleProxy = "0x5e76821C3c1AbB9fD6E310224804556C61D860e0" + OptimismMintableERC20FactoryProxy = "0x7a69a90d8ea11E9618855da55D09E6F953730686" + OptimismPortalProxy = "0x91493a61ab83b62943E6dCAa5475Dd330704Cc84" + SystemConfigProxy = "0x886B187C3D293B1449A3A0F23Ca9e2269E0f2664" + ProxyAdmin = "0xb570F4aD27e7De879A2E4F2F3DE27dBaBc20E9B9" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" + DelayedWETHProxy = "0x0000000000000000000000000000000000000000" + DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x0000000000000000000000000000000000000000" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x0000000000000000000000000000000000000000" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "Binary Mainnet" + chain_id = 624 + public_rpc = "https://rpc.zero.thebinaryholdings.com" + sequencer_rpc = "https://sequencer.bnry.mainnet.zeeve.net" + explorer = "https://explorer.thebinaryholdings.com/" + superchain_level = 0 + batch_inbox_addr = "0xFF00000000000000000000000000000000000624" + canyon_time = 0 + delta_time = 0 + ecotone_time = 0 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + gas_paying_token = "0x04E9D7e336f79Cdab911b06133D3Ca2Cd0721ce3" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1719397463 + [superchains.chains.genesis.l1] + hash = "0xdcc5838ee3dd0af995c87bec9614a09f08dd8979014876b42fd7e3ae044dd8c4" + number = 20175246 + [superchains.chains.genesis.l2] + hash = "0xe222b4b07ee9c885d13ee341823c92aa449f9769ac68fb5f1e1d4e602a990a4a" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x7f9D9c1BCE1062E1077845eA39a0303429600a06" + overhead = "0x0000000000000000000000000000000000000000000000000000000000000000" + scalar = "0x010000000000000000000000000000000000000000000000000c5fc500000558" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0x25A6E7c6f3d0fE89A656Fcf065614B74E55099fF" + ProxyAdminOwner = "0x48EC051349dDc7E8baBafCBfe27696ECF2A8a8B3" + Guardian = "0x87aab081Ac9F8ce80fb048f23280DF019036BA1d" + Challenger = "0x79DdF0745D14783cDC2a05624c585Ddce07F4A02" + Proposer = "0x2b6cD940ABE0CAF2fd89155b99522548c00EBaB1" + UnsafeBlockSigner = "0xDbad225D1C0DaBc27f6a9d250dBb136413C0DFb4" + BatchSubmitter = "0x7f9D9c1BCE1062E1077845eA39a0303429600a06" + AddressManager = "0x8173904703995c6BbA59a42B8bBf8405F978758a" + L1CrossDomainMessengerProxy = "0x807d21e416434ae92c8E5bcA4d506781aFbBa380" + L1ERC721BridgeProxy = "0x1b396e4dC6ECB0be33CF01C5a34E1a3a7D03c378" + L1StandardBridgeProxy = "0xD1B30378CBF968E5525e8835219A5726A1e71D10" + L2OutputOracleProxy = "0x012f4baa6e0F5Ac4dFDF47BDdd9CF68a2B17821e" + OptimismMintableERC20FactoryProxy = "0xa641e14B685b5E652865e14A4fBc07e51371D124" + OptimismPortalProxy = "0x5ff88fcF8e9947f45F4cAf8FFd5231B5DdF05e0A" + SystemConfigProxy = "0x7aC7e5989EaC278B7BbfeF560871a2026baD472c" + ProxyAdmin = "0x38593Cce8FaB9887Ef9760f5F6aB3d6C595143cF" + SuperchainConfig = "0x34bb53D7C525114A27F0FE2aF91bdDAd186abb12" + AnchorStateRegistryProxy = "0x275Abd1eB1FBaAB40Dcef5f3A588e2dF65801edc" + DelayedWETHProxy = "0x161914F701d090824c1A8a0f4e5666938f12848d" + DisputeGameFactoryProxy = "0x0D7e0590c58e4aC9B14B3eD6163CF55223931699" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x4e66D89DDF5A9d86836ABb1d05Ff8fDb5aD32c9A" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0xB9fF3A5835144b0d2F4267A21e0c74458907c870" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "Lyra Chain" + chain_id = 957 + public_rpc = "https://rpc.lyra.finance" + sequencer_rpc = "https://rpc.lyra.finance" + explorer = "https://explorer.lyra.finance" + superchain_level = 0 + superchain_time = 0 + batch_inbox_addr = "0x5f7f7f6DB967F0ef10BdA0678964DBA185d16c50" + canyon_time = 1704992401 + delta_time = 1708560000 + ecotone_time = 1710374401 + fjord_time = 1720627201 + granite_time = 1726070401 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1700021615 + [superchains.chains.genesis.l1] + hash = "0x00b06b23108483a0b6af8ff726b5ed3f508b7986f72c12679b10d72c05839716" + number = 18574841 + [superchains.chains.genesis.l2] + hash = "0x047f535b3da7ad4f96d353b5a439740b7591413daee0e2f27dd3aabb24581af2" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x14e4E97bDc195d399Ad8E7FC14451C279FE04c8e" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" + ProxyAdminOwner = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" + Guardian = "0x91F4be0C264FAFA1fEd75c4440910Cba2cAd98e8" + Challenger = "0x91F4be0C264FAFA1fEd75c4440910Cba2cAd98e8" + Proposer = "0x03e820562ffd2e0390787caD706EaF1FF98C2608" + UnsafeBlockSigner = "0xB71B58FfE538628557433dbBfA08d45ee5a69B44" + BatchSubmitter = "0x14e4E97bDc195d399Ad8E7FC14451C279FE04c8e" + AddressManager = "0xC845F9C4004EB35a8bde8ad89C4760a9c0e65CAB" + L1CrossDomainMessengerProxy = "0x5456f02c08e9A018E42C39b351328E5AA864174A" + L1ERC721BridgeProxy = "0x6CC3268794c5d3E3d9d52adEfC748B59d536cb22" + L1StandardBridgeProxy = "0x61E44dC0dae6888B5a301887732217d5725B0bFf" + L2OutputOracleProxy = "0x1145E7848c8B64c6cab86Fd6D378733385c5C3Ba" + OptimismMintableERC20FactoryProxy = "0x08Dea366F26C25a08C8D1C3568ad07d1e587136d" + OptimismPortalProxy = "0x85eA9c11cf3D4786027F7FD08F4406b15777e5f8" + SystemConfigProxy = "0x0e4C4CDd01ceCB01070E9Fdfe7600871e4ae996e" + ProxyAdmin = "0x35d5D43271548c984662d4879FBc8e041Bc1Ff93" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" + DelayedWETHProxy = "0x0000000000000000000000000000000000000000" + DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x0000000000000000000000000000000000000000" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x0000000000000000000000000000000000000000" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "Metal L2" + chain_id = 1750 + public_rpc = "https://rpc.metall2.com" + sequencer_rpc = "https://rpc.metall2.com" + explorer = "https://explorer.metall2.com" + superchain_level = 0 + standard_chain_candidate = true + superchain_time = 0 + batch_inbox_addr = "0xc83f7D9F2D4A76E81145849381ABA02602373723" + canyon_time = 0 + delta_time = 0 + ecotone_time = 0 + fjord_time = 1720627201 + granite_time = 1726070401 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1711563515 + [superchains.chains.genesis.l1] + hash = "0x2493565ce8472656b7c22377c8d4d8ef5d17f78392c799ca5f2429b01e2c159c" + number = 19527340 + [superchains.chains.genesis.l2] + hash = "0xd31c12ffff2d563897ad9a041c0d26790d635911bdbbfa589347fa955f75281e" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0xC94C243f8fb37223F3EB2f7961F7072602A51B8B" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" + ProxyAdminOwner = "0x5a0Aae59D09fccBdDb6C6CcEB07B7279367C3d2A" + Guardian = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" + Challenger = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" + Proposer = "0xC8187d40AD440328104A52BBed2D8Efc5ab1F1F6" + UnsafeBlockSigner = "0x4a65F5da5e80DEFfEA844eAa15CE130e80605dc5" + BatchSubmitter = "0xC94C243f8fb37223F3EB2f7961F7072602A51B8B" + AddressManager = "0xd4b1EC0DEc3C7F12abD3ec27B7514880ae1C3a37" + L1CrossDomainMessengerProxy = "0x0a47A44f1B2bb753474f8c830322554A96C9934D" + L1ERC721BridgeProxy = "0x50D700e97967F9115e3f999bDB263d69F6704680" + L1StandardBridgeProxy = "0x6d0f65D59b55B0FEC5d2d15365154DcADC140BF3" + L2OutputOracleProxy = "0x3B1F7aDa0Fcc26B13515af752Dd07fB1CAc11426" + OptimismMintableERC20FactoryProxy = "0x1aaab4E20d2e4Bb992b5BCA2125e8bd3588c8730" + OptimismPortalProxy = "0x3F37aBdE2C6b5B2ed6F8045787Df1ED1E3753956" + SystemConfigProxy = "0x7BD909970B0EEdcF078De6Aeff23ce571663b8aA" + ProxyAdmin = "0x37Ff0ae34dadA1A95A4251d10ef7Caa868c7AC99" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" + DelayedWETHProxy = "0x0000000000000000000000000000000000000000" + DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x0000000000000000000000000000000000000000" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x0000000000000000000000000000000000000000" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "RACE Mainnet" + chain_id = 6805 + public_rpc = "https://racemainnet.io" + sequencer_rpc = "https://racemainnet.io" + explorer = "https://racescan.io/" + superchain_level = 0 + batch_inbox_addr = "0xFF00000000000000000000000000000000006805" + canyon_time = 0 + delta_time = 0 + ecotone_time = 0 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1720421591 + [superchains.chains.genesis.l1] + hash = "0xb6fd41e6c3515172c36d3912046264475eaad84c2c56e99d74f4abd1a75b63c9" + number = 20260129 + [superchains.chains.genesis.l2] + hash = "0xa864791943836c37b40ea688f3853f2198afb683a3e168d48bfa76c9896e3e65" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x8CDa8351236199AF7532baD53D683Ddd9B275d89" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0xBac1ad52745162c0aA3711fe88Df1Cc67034a3B9" + ProxyAdminOwner = "0x5A669B2193718F189b0576c0cdcedfEd6f40F9Ea" + Guardian = "0x2E7B9465B25C081c07274A31DbD05C6146f67961" + Challenger = "0x2E7B9465B25C081c07274A31DbD05C6146f67961" + Proposer = "0x88D58BFbCD70c25409b67117fC1CDfeFDA113a78" + UnsafeBlockSigner = "0x9b5639D472D6764b70F5046Ac0B13438718398E0" + BatchSubmitter = "0x8CDa8351236199AF7532baD53D683Ddd9B275d89" + AddressManager = "0x3d2BdE87466Cae97011702D2C305fd40EEBbbF0a" + L1CrossDomainMessengerProxy = "0xf54B2BAEF894cfF5511A5722Acaac0409F2F2d89" + L1ERC721BridgeProxy = "0x0f33D824d74180598311b3025095727BeA61f219" + L1StandardBridgeProxy = "0x680969A6c58183987c8126ca4DE6b59C6540Cd2a" + L2OutputOracleProxy = "0x8bF8442d49d52377d735a90F19657a29f29aA83c" + OptimismMintableERC20FactoryProxy = "0x1d1c4C89AD5FF486c3C67E3DD84A22CF05420711" + OptimismPortalProxy = "0x0485Ca8A73682B3D3f5ae98cdca1E5b512E728e9" + SystemConfigProxy = "0xCf6A32dB8b3313b3d439CE6909511c2c3415fa32" + ProxyAdmin = "0x9B3C6D1d33F1fd82Ebb8dFbE38dA162B329De191" + SuperchainConfig = "0xCB73B7348705a9F925643150Eb00350719380FF8" + AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" + DelayedWETHProxy = "0x0000000000000000000000000000000000000000" + DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x0000000000000000000000000000000000000000" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x0000000000000000000000000000000000000000" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "Base" + chain_id = 8453 + public_rpc = "https://mainnet.base.org" + sequencer_rpc = "https://mainnet-sequencer.base.org" + explorer = "https://explorer.base.org" + superchain_level = 0 + standard_chain_candidate = true + superchain_time = 0 + batch_inbox_addr = "0xFf00000000000000000000000000000000008453" + canyon_time = 1704992401 + delta_time = 1708560000 + ecotone_time = 1710374401 + fjord_time = 1720627201 + granite_time = 1726070401 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1686789347 + [superchains.chains.genesis.l1] + hash = "0x5c13d307623a926cd31415036c8b7fa14572f9dac64528e857a470511fc30771" + number = 17481768 + [superchains.chains.genesis.l2] + hash = "0xf712aa9241cc24369b143cf6dce85f0902a9731e70d66818a3a5845b296c73dd" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x5050F69a9786F081509234F1a7F4684b5E5b76C9" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0x14536667Cd30e52C0b458BaACcB9faDA7046E056" + ProxyAdminOwner = "0x7bB41C3008B3f03FE483B28b8DB90e19Cf07595c" + Guardian = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" + Challenger = "0x6F8C5bA3F59ea3E76300E3BEcDC231D656017824" + Proposer = "0x642229f238fb9dE03374Be34B0eD8D9De80752c5" + UnsafeBlockSigner = "0xAf6E19BE0F9cE7f8afd49a1824851023A8249e8a" + BatchSubmitter = "0x5050F69a9786F081509234F1a7F4684b5E5b76C9" + AddressManager = "0x8EfB6B5c4767B09Dc9AA6Af4eAA89F749522BaE2" + L1CrossDomainMessengerProxy = "0x866E82a600A1414e583f7F13623F1aC5d58b0Afa" + L1ERC721BridgeProxy = "0x608d94945A64503E642E6370Ec598e519a2C1E53" + L1StandardBridgeProxy = "0x3154Cf16ccdb4C6d922629664174b904d80F2C35" + L2OutputOracleProxy = "0x56315b90c40730925ec5485cf004d835058518A0" + OptimismMintableERC20FactoryProxy = "0x05cc379EBD9B30BbA19C6fA282AB29218EC61D84" + OptimismPortalProxy = "0x49048044D57e1C92A77f79988d21Fa8fAF74E97e" + SystemConfigProxy = "0x73a79Fab69143498Ed3712e519A88a918e1f4072" + ProxyAdmin = "0x0475cBCAebd9CE8AfA5025828d5b98DFb67E059E" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" + DelayedWETHProxy = "0x0000000000000000000000000000000000000000" + DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x0000000000000000000000000000000000000000" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x0000000000000000000000000000000000000000" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "Mode" + chain_id = 34443 + public_rpc = "https://mainnet.mode.network" + sequencer_rpc = "https://mainnet-sequencer.mode.network" + explorer = "https://explorer.mode.network" + superchain_level = 0 + standard_chain_candidate = true + superchain_time = 0 + batch_inbox_addr = "0x24E59d9d3Bd73ccC28Dc54062AF7EF7bFF58Bd67" + canyon_time = 1704992401 + delta_time = 1708560000 + ecotone_time = 1710374401 + fjord_time = 1720627201 + granite_time = 1726070401 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1700167583 + [superchains.chains.genesis.l1] + hash = "0xf9b1b22a7ef9d13f063ea467bcb70fb6e9f29698ecb7366a2cdf5af2165cacee" + number = 18586927 + [superchains.chains.genesis.l2] + hash = "0xb0f682e12fc555fd5ce8fce51a59a67d66a5b46be28611a168260a549dac8a9b" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x99199a22125034c808ff20f377d91187E8050F2E" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" + ProxyAdminOwner = "0x5a0Aae59D09fccBdDb6C6CcEB07B7279367C3d2A" + Guardian = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" + Challenger = "0x309Fe2536d01867018D120b40e4676723C53A14C" + Proposer = "0x674F64D64Ddc198db83cd9047dF54BF89cCD0ddB" + UnsafeBlockSigner = "0xa7fA9CA4ac88686A542C0f830d7378eAB4A0278F" + BatchSubmitter = "0x99199a22125034c808ff20f377d91187E8050F2E" + AddressManager = "0x50eF494573f28Cad6B64C31b7a00Cdaa48306e15" + L1CrossDomainMessengerProxy = "0x95bDCA6c8EdEB69C98Bd5bd17660BaCef1298A6f" + L1ERC721BridgeProxy = "0x2901dA832a4D0297FF0691100A8E496626cc626D" + L1StandardBridgeProxy = "0x735aDBbE72226BD52e818E7181953f42E3b0FF21" + L2OutputOracleProxy = "0x4317ba146D4933D889518a3e5E11Fe7a53199b04" + OptimismMintableERC20FactoryProxy = "0x69216395A62dFb243C05EF4F1C27AF8655096a95" + OptimismPortalProxy = "0x8B34b14c7c7123459Cf3076b8Cb929BE097d0C07" + SystemConfigProxy = "0x5e6432F18Bc5d497B1Ab2288a025Fbf9D69E2221" + ProxyAdmin = "0x470d87b1dae09a454A43D1fD772A561a03276aB7" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" + DelayedWETHProxy = "0x0000000000000000000000000000000000000000" + DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x0000000000000000000000000000000000000000" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x0000000000000000000000000000000000000000" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "Zora" + chain_id = 7777777 + public_rpc = "https://rpc.zora.energy" + sequencer_rpc = "https://rpc.zora.energy" + explorer = "https://explorer.zora.energy" + superchain_level = 0 + standard_chain_candidate = true + superchain_time = 0 + batch_inbox_addr = "0x6F54Ca6F6EdE96662024Ffd61BFd18f3f4e34DFf" + canyon_time = 1704992401 + delta_time = 1708560000 + ecotone_time = 1710374401 + fjord_time = 1720627201 + granite_time = 1726070401 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1686693839 + [superchains.chains.genesis.l1] + hash = "0xbdbd2847f7aa5f7cd1bd4c9f904057f4ba0b498c7e380199c01d240e3a41a84f" + number = 17473923 + [superchains.chains.genesis.l2] + hash = "0x47555a45a1af8d4728ca337a1e48375a83919b1ea16591e070a07388b7364e29" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x625726c858dBF78c0125436C943Bf4b4bE9d9033" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0xC72aE5c7cc9a332699305E29F68Be66c73b60542" + ProxyAdminOwner = "0x5a0Aae59D09fccBdDb6C6CcEB07B7279367C3d2A" + Guardian = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" + Challenger = "0xcA4571b1ecBeC86Ea2E660d242c1c29FcB55Dc72" + Proposer = "0x48247032092e7b0ecf5dEF611ad89eaf3fC888Dd" + UnsafeBlockSigner = "0x3Dc8Dfd0709C835cAd15a6A27e089FF4cF4C9228" + BatchSubmitter = "0x625726c858dBF78c0125436C943Bf4b4bE9d9033" + AddressManager = "0xEF8115F2733fb2033a7c756402Fc1deaa56550Ef" + L1CrossDomainMessengerProxy = "0xdC40a14d9abd6F410226f1E6de71aE03441ca506" + L1ERC721BridgeProxy = "0x83A4521A3573Ca87f3a971B169C5A0E1d34481c3" + L1StandardBridgeProxy = "0x3e2Ea9B92B7E48A52296fD261dc26fd995284631" + L2OutputOracleProxy = "0x9E6204F750cD866b299594e2aC9eA824E2e5f95c" + OptimismMintableERC20FactoryProxy = "0xc52BC7344e24e39dF1bf026fe05C4e6E23CfBcFf" + OptimismPortalProxy = "0x1a0ad011913A150f69f6A19DF447A0CfD9551054" + SystemConfigProxy = "0xA3cAB0126d5F504B071b81a3e8A2BBBF17930d86" + ProxyAdmin = "0xD4ef175B9e72cAEe9f1fe7660a6Ec19009903b49" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" + DelayedWETHProxy = "0x0000000000000000000000000000000000000000" + DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x0000000000000000000000000000000000000000" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x0000000000000000000000000000000000000000" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + +[[superchains]] + name = "sepolia" + [superchains.config] + name = "Sepolia" + protocol_versions_addr = "0x79ADD5713B383DAa0a138d3C4780C7A1804a8090" + superchain_config_addr = "0xC2Be75506d5724086DEB7245bd260Cc9753911Be" + [superchains.config.l1] + chain_id = 11155111 + public_rpc = "https://ethereum-sepolia-rpc.publicnode.com" + explorer = "https://sepolia.etherscan.io" + + [[superchains.chains]] + name = "Mode Testnet" + chain_id = 919 + public_rpc = "https://sepolia.mode.network" + sequencer_rpc = "https://sepolia.mode.network" + explorer = "https://sepolia.explorer.mode.network" + superchain_level = 0 + standard_chain_candidate = true + superchain_time = 1703203200 + batch_inbox_addr = "0xcDDaE6148dA1E003C230E4527f9baEdc8a204e7E" + canyon_time = 1703203200 + delta_time = 1703203200 + ecotone_time = 1708534800 + fjord_time = 1716998400 + granite_time = 1723478400 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1687867932 + [superchains.chains.genesis.l1] + hash = "0x4370cafe528a1b8f2aaffc578094731daf69ff82fd9edc30d2d842d3763f3410" + number = 3778382 + [superchains.chains.genesis.l2] + hash = "0x13c352562289a88ed33087a51b6b6c859a27709c8555c9def7cb9757c043acad" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x4e6BD53883107B063c502dDd49F9600Dc51b3DDc" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C" + ProxyAdminOwner = "0x1Eb2fFc903729a0F03966B917003800b145F56E2" + Guardian = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" + Challenger = "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7" + Proposer = "0xe9e08A478e3a773c1B5D59014A0FDb901e6d1d69" + UnsafeBlockSigner = "0x93A14E6894eEB4FF6a373E1Ad4f498c3a207afe4" + BatchSubmitter = "0x4e6BD53883107B063c502dDd49F9600Dc51b3DDc" + AddressManager = "0x83D45725d6562d8CD717673D6bb4c67C07dC1905" + L1CrossDomainMessengerProxy = "0xc19a60d9E8C27B9A43527c3283B4dd8eDC8bE15C" + L1ERC721BridgeProxy = "0x015a8c2e0a5fEd579dbb05fd290e413Adc6FC24A" + L1StandardBridgeProxy = "0xbC5C679879B2965296756CD959C3C739769995E2" + L2OutputOracleProxy = "0x2634BD65ba27AB63811c74A63118ACb312701Bfa" + OptimismMintableERC20FactoryProxy = "0x00F7ab8c72D32f55cFf15e8901C2F9f2BF29A3C0" + OptimismPortalProxy = "0x320e1580effF37E008F1C92700d1eBa47c1B23fD" + SystemConfigProxy = "0x15cd4f6e0CE3B4832B33cB9c6f6Fe6fc246754c2" + ProxyAdmin = "0xE7413127F29E050Df65ac3FC9335F85bB10091AE" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" + DelayedWETHProxy = "0x0000000000000000000000000000000000000000" + DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x0000000000000000000000000000000000000000" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x0000000000000000000000000000000000000000" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "Metal L2 Testnet" + chain_id = 1740 + public_rpc = "https://testnet.rpc.metall2.com" + sequencer_rpc = "https://testnet.rpc.metall2.com" + explorer = "https://testnet.explorer.metall2.com" + superchain_level = 0 + standard_chain_candidate = true + batch_inbox_addr = "0x24567B64a86A4c966655fba6502a93dFb701E316" + canyon_time = 1708129622 + delta_time = 1708385400 + ecotone_time = 1708534800 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1708129620 + [superchains.chains.genesis.l1] + hash = "0x6a10927c70985f75898c48235b620acb2a48e9c777a40022f9dbad1b0c96a9c1" + number = 5304030 + [superchains.chains.genesis.l2] + hash = "0xd24cf8e46b189b0c128dab4e46168520e3a4cdd390b239e8cc1e5abd22a629ae" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0xdb80Eca386AC72a55510e33CF9CF7533e75916eE" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C" + ProxyAdminOwner = "0x1Eb2fFc903729a0F03966B917003800b145F56E2" + Guardian = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" + Challenger = "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7" + Proposer = "0x0000000000000000000000000000000000000000" + UnsafeBlockSigner = "0x0000000000000000000000000000000000000000" + BatchSubmitter = "0xdb80Eca386AC72a55510e33CF9CF7533e75916eE" + AddressManager = "0x394f844B9A0FC876935d1b0b791D9e94Ad905e8b" + L1CrossDomainMessengerProxy = "0x5D335Aa7d93102110879e3B54985c5F08146091E" + L1ERC721BridgeProxy = "0x5d6cE6917dBeeacF010c96BfFdaBE89e33a30309" + L1StandardBridgeProxy = "0x21530aAdF4DCFb9c477171400E40d4ef615868BE" + L2OutputOracleProxy = "0x75a6B961c8da942Ee03CA641B09C322549f6FA98" + OptimismMintableERC20FactoryProxy = "0x49Ff2C4be882298e8CA7DeCD195c207c42B45F66" + OptimismPortalProxy = "0x01D4dfC994878682811b2980653D03E589f093cB" + SystemConfigProxy = "0x5D63A8Dc2737cE771aa4a6510D063b6Ba2c4f6F2" + ProxyAdmin = "0xF7Bc4b3a78C7Dd8bE9B69B3128EEB0D6776Ce18A" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" + DelayedWETHProxy = "0x0000000000000000000000000000000000000000" + DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x0000000000000000000000000000000000000000" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x0000000000000000000000000000000000000000" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "RACE Testnet" + chain_id = 6806 + public_rpc = "https://racetestnet.io" + sequencer_rpc = "https://racetestnet.io" + explorer = "https://testnet.racescan.io/" + superchain_level = 0 + batch_inbox_addr = "0xff00000000000000000000000000000000006806" + canyon_time = 0 + delta_time = 0 + ecotone_time = 0 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1719646560 + [superchains.chains.genesis.l1] + hash = "0x28dd1dd74080560ef0b02f8f1ae31d1be75b01a70a5be6ef22e673cec538770f" + number = 6210400 + [superchains.chains.genesis.l2] + hash = "0x994d67464c3368b8eb6f9770087399486b25d721a1868b95bb37de327b49ab89" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x584D61A30C7Ef1E8D547eE02099dADC487f49889" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0xE6869aF6c871614df04902870Bb13d4505E1586c" + ProxyAdminOwner = "0xAc78E9B3Aa9373AE4bE2Ba5Bc9F716d7A746A65E" + Guardian = "0xE6869aF6c871614df04902870Bb13d4505E1586c" + Challenger = "0xE6869aF6c871614df04902870Bb13d4505E1586c" + Proposer = "0x5a145E3F466FD6cC095214C700359df7894BaD21" + UnsafeBlockSigner = "0x89eA88ef4AC23f4C7Fdc611Fc9cD1c50DF702C2C" + BatchSubmitter = "0x584D61A30C7Ef1E8D547eE02099dADC487f49889" + AddressManager = "0x1B573Db1000eA419B6dE8eB482C6d394179Bd1A3" + L1CrossDomainMessengerProxy = "0xdaeab17598938A4f27E50AC771249Ad7df12Ea7D" + L1ERC721BridgeProxy = "0xBafb1a6e54e7750aF29489D65888d1c96Dfd66Df" + L1StandardBridgeProxy = "0x289179e9d43A35D47239456251F9c2fdbf9fbeA2" + L2OutputOracleProxy = "0xccac2B8FFc4f778242105F3a9E6B3Ae3F827fC6a" + OptimismMintableERC20FactoryProxy = "0xbd023e7F08AE0274dCEd397D4B6630D697aC738A" + OptimismPortalProxy = "0xF2891fc6819CDd6BD9221874619BB03A6277d72A" + SystemConfigProxy = "0x07e7A3F25aA73dA15bc19B71FEF8f5511342a409" + ProxyAdmin = "0x4a0E8415e3eB85E7393445FD8E588283b62216C8" + SuperchainConfig = "0x1696a64C7F170E46D32088E8eC29193300C35817" + AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" + DelayedWETHProxy = "0x0000000000000000000000000000000000000000" + DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x0000000000000000000000000000000000000000" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x0000000000000000000000000000000000000000" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "Base Sepolia Testnet" + chain_id = 84532 + public_rpc = "https://sepolia.base.org" + sequencer_rpc = "https://sepolia-sequencer.base.org" + explorer = "https://sepolia-explorer.base.org" + superchain_level = 0 + standard_chain_candidate = true + superchain_time = 0 + batch_inbox_addr = "0xfF00000000000000000000000000000000084532" + canyon_time = 1699981200 + delta_time = 1703203200 + ecotone_time = 1708534800 + fjord_time = 1716998400 + granite_time = 1723478400 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 10 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1695768288 + [superchains.chains.genesis.l1] + hash = "0xcac9a83291d4dec146d6f7f69ab2304f23f5be87b1789119a0c5b1e4482444ed" + number = 4370868 + [superchains.chains.genesis.l2] + hash = "0x0dcc9e089e30b90ddfc55be9a37dd15bc551aeee999d2e2b51414c54eaf934e4" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x6CDEbe940BC0F26850285cacA097C11c33103E47" + overhead = "0x0000000000000000000000000000000000000000000000000000000000000834" + scalar = "0x00000000000000000000000000000000000000000000000000000000000f4240" + gasLimit = 25000000 + [superchains.chains.addresses] + SystemConfigOwner = "0x0fe884546476dDd290eC46318785046ef68a0BA9" + ProxyAdminOwner = "0x0fe884546476dDd290eC46318785046ef68a0BA9" + Guardian = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" + Challenger = "0xDa3037Ff70Ac92CD867c683BD807e5A484857405" + Proposer = "0x20044a0d104E9e788A0C984A2B7eAe615afD046b" + UnsafeBlockSigner = "0xb830b99c95Ea32300039624Cb567d324D4b1D83C" + BatchSubmitter = "0x6CDEbe940BC0F26850285cacA097C11c33103E47" + AddressManager = "0x709c2B8ef4A9feFc629A8a2C1AF424Dc5BD6ad1B" + L1CrossDomainMessengerProxy = "0xC34855F4De64F1840e5686e64278da901e261f20" + L1ERC721BridgeProxy = "0x21eFD066e581FA55Ef105170Cc04d74386a09190" + L1StandardBridgeProxy = "0xfd0Bf71F60660E2f608ed56e1659C450eB113120" + L2OutputOracleProxy = "0x0000000000000000000000000000000000000000" + OptimismMintableERC20FactoryProxy = "0xb1efB9650aD6d0CC1ed3Ac4a0B7f1D5732696D37" + OptimismPortalProxy = "0x49f53e41452C74589E85cA1677426Ba426459e85" + SystemConfigProxy = "0xf272670eb55e895584501d564AfEB048bEd26194" + ProxyAdmin = "0x0389E59Aa0a41E4A413Ae70f0008e76CAA34b1F3" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x4C8BA32A5DAC2A720bb35CeDB51D6B067D104205" + DelayedWETHProxy = "0x7698b262B7a534912c8366dD8a531672deEC634e" + DisputeGameFactoryProxy = "0xd6E6dBf4F7EA0ac412fD8b65ED297e64BB7a06E1" + FaultDisputeGame = "0x8A9bA50a785c3868bEf1FD4924b640A5e0ed54CF" + MIPS = "0xFF760A87E41144b336E29b6D4582427dEBdB6dee" + PermissionedDisputeGame = "0x3f5c770f17A6982d2B3Ac77F6fDC93BFE0330E17" + PreimageOracle = "0x627F825CBd48c4102d36f287be71f4234426b9e4" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "OP Sepolia Testnet" + chain_id = 11155420 + public_rpc = "https://sepolia.optimism.io" + sequencer_rpc = "https://sepolia-sequencer.optimism.io" + explorer = "https://sepolia-optimistic.etherscan.io" + superchain_level = 1 + superchain_time = 0 + batch_inbox_addr = "0xff00000000000000000000000000000011155420" + canyon_time = 1699981200 + delta_time = 1703203200 + ecotone_time = 1708534800 + fjord_time = 1716998400 + granite_time = 1723478400 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1691802540 + [superchains.chains.genesis.l1] + hash = "0x48f520cf4ddaf34c8336e6e490632ea3cf1e5e93b0b2bc6e917557e31845371b" + number = 4071408 + [superchains.chains.genesis.l2] + hash = "0x102de6ffb001480cc9b8b548fd05c34cd4f46ae4aa91759393db90ea0409887d" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x8F23BB38F531600e5d8FDDaAEC41F13FaB46E98c" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301" + ProxyAdminOwner = "0x1Eb2fFc903729a0F03966B917003800b145F56E2" + Guardian = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" + Challenger = "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301" + Proposer = "0x49277EE36A024120Ee218127354c4a3591dc90A9" + UnsafeBlockSigner = "0x57CACBB0d30b01eb2462e5dC940c161aff3230D3" + BatchSubmitter = "0x8F23BB38F531600e5d8FDDaAEC41F13FaB46E98c" + AddressManager = "0x9bFE9c5609311DF1c011c47642253B78a4f33F4B" + L1CrossDomainMessengerProxy = "0x58Cc85b8D04EA49cC6DBd3CbFFd00B4B8D6cb3ef" + L1ERC721BridgeProxy = "0xd83e03D576d23C9AEab8cC44Fa98d058D2176D1f" + L1StandardBridgeProxy = "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1" + L2OutputOracleProxy = "0x0000000000000000000000000000000000000000" + OptimismMintableERC20FactoryProxy = "0x868D59fF9710159C2B330Cc0fBDF57144dD7A13b" + OptimismPortalProxy = "0x16Fc5058F25648194471939df75CF27A2fdC48BC" + SystemConfigProxy = "0x034edD2A225f7f429A63E0f1D2084B9E0A93b538" + ProxyAdmin = "0x189aBAAaa82DfC015A588A7dbaD6F13b1D3485Bc" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x218CD9489199F321E1177b56385d333c5B598629" + DelayedWETHProxy = "0xF3D833949133e4E4D3551343494b34079598EA5a" + DisputeGameFactoryProxy = "0x05F9613aDB30026FFd634f38e5C4dFd30a197Fa1" + FaultDisputeGame = "0xD5Bc8c45692aada756f2d68f0a2002d6Bf130C42" + MIPS = "0xFF760A87E41144b336E29b6D4582427dEBdB6dee" + PermissionedDisputeGame = "0xBEA4384faCBcf51279962fbCFb8f16F9eD2fe0C6" + PreimageOracle = "0x627F825CBd48c4102d36f287be71f4234426b9e4" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "Zora Sepolia Testnet" + chain_id = 999999999 + public_rpc = "https://sepolia.rpc.zora.energy" + sequencer_rpc = "https://sepolia.rpc.zora.energy" + explorer = "https://sepolia.explorer.zora.energy" + superchain_level = 0 + standard_chain_candidate = true + superchain_time = 0 + batch_inbox_addr = "0xCd734290E4bd0200dAC631c7D4b9E8a33234e91f" + canyon_time = 1699981200 + delta_time = 1703203200 + ecotone_time = 1708534800 + fjord_time = 1716998400 + granite_time = 1723478400 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1698080004 + [superchains.chains.genesis.l1] + hash = "0xf782446a2487d900addb5d466a8597c7c543b59fa9aaa154d413830238f8798a" + number = 4548041 + [superchains.chains.genesis.l2] + hash = "0x8b17d2d52564a5a90079d9c860e1386272579e87b17ea27a3868513f53facd74" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x3Cd868E221A3be64B161D596A7482257a99D857f" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C" + ProxyAdminOwner = "0x1Eb2fFc903729a0F03966B917003800b145F56E2" + Guardian = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" + Challenger = "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7" + Proposer = "0xe8326a5839175dE7f467e66D8bB443aa70DA1c3e" + UnsafeBlockSigner = "0x3609513933100689bd1f84782529A99239842344" + BatchSubmitter = "0x3Cd868E221A3be64B161D596A7482257a99D857f" + AddressManager = "0x27c9392144DFcB6dab113F737356C32435cD1D55" + L1CrossDomainMessengerProxy = "0x1bDBC0ae22bEc0c2f08B4dd836944b3E28fe9b7A" + L1ERC721BridgeProxy = "0x16B0a4f451c4CB567703367e587E15Ac108e4311" + L1StandardBridgeProxy = "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB" + L2OutputOracleProxy = "0x2615B481Bd3E5A1C0C7Ca3Da1bdc663E8615Ade9" + OptimismMintableERC20FactoryProxy = "0x5F3bdd57f01e88cE2F88f00685D30D6eb51A187c" + OptimismPortalProxy = "0xeffE2C6cA9Ab797D418f0D91eA60807713f3536f" + SystemConfigProxy = "0xB54c7BFC223058773CF9b739cC5bd4095184Fb08" + ProxyAdmin = "0xE17071F4C216Eb189437fbDBCc16Bb79c4efD9c2" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" + DelayedWETHProxy = "0x0000000000000000000000000000000000000000" + DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x0000000000000000000000000000000000000000" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x0000000000000000000000000000000000000000" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + +[[superchains]] + name = "sepolia-dev-0" + [superchains.config] + name = "Sepolia Dev 0" + protocol_versions_addr = "0x252CbE9517F731C618961D890D534183822dcC8d" + superchain_config_addr = "0x02d91Cf852423640d93920BE0CAdceC0E7A00FA7" + [superchains.config.l1] + chain_id = 11155111 + public_rpc = "https://ethereum-sepolia-rpc.publicnode.com" + explorer = "https://sepolia.etherscan.io" + + [[superchains.chains]] + name = "OP Labs Sepolia devnet 0" + chain_id = 11155421 + public_rpc = "" + sequencer_rpc = "" + explorer = "" + superchain_level = 0 + superchain_time = 0 + batch_inbox_addr = "0xFf00000000000000000000000000000011155421" + canyon_time = 0 + delta_time = 0 + ecotone_time = 1706634000 + fjord_time = 1715961600 + granite_time = 1723046400 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1706484048 + [superchains.chains.genesis.l1] + hash = "0x5639be97000fec7131a880b19b664cae43f975c773f628a08a9bb658c2a68df0" + number = 5173577 + [superchains.chains.genesis.l2] + hash = "0x027ae1f4f9a441f9c8a01828f3b6d05803a0f524c07e09263264a38b755f804b" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x19CC7073150D9f5888f09E0e9016d2a39667df14" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 30000000 + [superchains.chains.addresses] + SystemConfigOwner = "0x8c20c40180751d93E939DDDee3517AE0d1EBeAd2" + ProxyAdminOwner = "0x4377BB0F0103992b31eC12b4d796a8687B8dC8E9" + Guardian = "0x8c20c40180751d93E939DDDee3517AE0d1EBeAd2" + Challenger = "0x8c20c40180751d93E939DDDee3517AE0d1EBeAd2" + Proposer = "0x95014c45078354Ff839f14192228108Eac82E00A" + UnsafeBlockSigner = "0xa95B83e39AA78B00F12fe431865B563793D97AF5" + BatchSubmitter = "0x19CC7073150D9f5888f09E0e9016d2a39667df14" + AddressManager = "0x3eb579b25F6b9547e0073c848389a768FD382296" + L1CrossDomainMessengerProxy = "0x18e72C15FEE4e995454b919EfaA61D8f116F82dd" + L1ERC721BridgeProxy = "0x1bb726658E039E8a9A4ac21A41fE5a0704760461" + L1StandardBridgeProxy = "0x6D8bC564EF04AaF355a10c3eb9b00e349dd077ea" + L2OutputOracleProxy = "0x0000000000000000000000000000000000000000" + OptimismMintableERC20FactoryProxy = "0xA16b8db3b5Cdbaf75158F34034B0537e528E17e2" + OptimismPortalProxy = "0x76114bd29dFcC7a9892240D317E6c7C2A281Ffc6" + SystemConfigProxy = "0xa6b72407e2dc9EBF84b839B69A24C88929cf20F7" + ProxyAdmin = "0x18d890A46A3556e7F36f28C79F6157BC7a59f867" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x03b82AE60989863BCEb0BbD442A70568e5AefB85" + DelayedWETHProxy = "0xE99696a028171e31a72828A196C27c2Dd670E1aa" + DisputeGameFactoryProxy = "0x2419423C72998eb1c6c15A235de2f112f8E38efF" + FaultDisputeGame = "0x54416A2E28E8cbC761fbce0C7f107307991282e5" + MIPS = "0xceDE5949A189aC60F41F1385a86DBce7Bd3B1943" + PermissionedDisputeGame = "0x50573970b291726B881b204eD9F3c1D507e504cD" + PreimageOracle = "0xB73342DdD69620e5Ab2Cc604Dad46434C2338025" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + + [[superchains.chains]] + name = "Base devnet 0" + chain_id = 11763072 + public_rpc = "" + sequencer_rpc = "" + explorer = "" + superchain_level = 0 + superchain_time = 1706634000 + batch_inbox_addr = "0xfF00000000000000000000000000000011763072" + canyon_time = 1698436800 + delta_time = 1706555000 + ecotone_time = 1706634000 + fjord_time = 1715961600 + granite_time = 1723046400 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 600 + data_availability_type = "eth-da" + [superchains.chains.optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [superchains.chains.genesis] + l2_time = 1695433056 + [superchains.chains.genesis.l1] + hash = "0x86252c512dc5bd7201d0532b31d50696ba84344a7cda545e04a98073a8e13d87" + number = 4344216 + [superchains.chains.genesis.l2] + hash = "0x1ab91449a7c65b8cd6c06f13e2e7ea2d10b6f9cbf5def79f362f2e7e501d2928" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x212dD524932bC43478688F91045F2682913ad8EE" + overhead = "0x0000000000000000000000000000000000000000000000000000000000000834" + scalar = "0x00000000000000000000000000000000000000000000000000000000000f4240" + gasLimit = 25000000 + [superchains.chains.addresses] + SystemConfigOwner = "0xAf6E0E871f38c7B653700F7CbAEDafaa2784D430" + ProxyAdminOwner = "0xAf6E0E871f38c7B653700F7CbAEDafaa2784D430" + Guardian = "0x4F43c7422a9b2AC4BC6145Bd4eE206EA73cF8266" + Challenger = "0x5a533AaAC6cd81605b301a1077BC393A94658B6D" + Proposer = "0xBcB04FC753D36dcEeBe9Df7E18E23c46D1fcEA3c" + UnsafeBlockSigner = "0xfd7bc3C58Fe4D4296F11F7843ebbA84D729A24B9" + BatchSubmitter = "0x212dD524932bC43478688F91045F2682913ad8EE" + AddressManager = "0x882a60911d00867Fe4ea632C479cc48e583A8D69" + L1CrossDomainMessengerProxy = "0x2cbD403d5BA3949D24ee4dF57805eaC612C2662f" + L1ERC721BridgeProxy = "0xc3016ED03E087d092d576B585F5222fFD9cadc10" + L1StandardBridgeProxy = "0x5638e55db5Fcf7A58df525F1098E8569C8DbA80c" + L2OutputOracleProxy = "0xB5901509329307E3f910f333Fa9C4B4A8EE7CE1A" + OptimismMintableERC20FactoryProxy = "0xEAa11178375e6B1078d815d6F9F85cBbb69b09Cd" + OptimismPortalProxy = "0x579c82A835B884336B632eeBeCC78FA08D3291Ec" + SystemConfigProxy = "0x7F67DC4959cb3E532B10A99F41bDD906C46FdFdE" + ProxyAdmin = "0xC5aE9023bFA79124ffA50169E1423E733D0166f1" + SuperchainConfig = "0x0000000000000000000000000000000000000000" + AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" + DelayedWETHProxy = "0x0000000000000000000000000000000000000000" + DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x0000000000000000000000000000000000000000" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x0000000000000000000000000000000000000000" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" diff --git a/superchain/internal/codegen/main.go b/superchain/internal/codegen/main.go index 3698935a1..d021a0a04 100644 --- a/superchain/internal/codegen/main.go +++ b/superchain/internal/codegen/main.go @@ -101,13 +101,6 @@ func main() { } fmt.Println("Wrote chainList.toml file") - // Write chainList.toml file to the rust-bindings directory so it can be included in crate releases. - err = os.WriteFile(filepath.Join(repositoryRoot, "bindings/rust-bindings/etc/chainList.toml"), buf.Bytes(), 0o644) - if err != nil { - panic(err) - } - fmt.Println("Wrote rust-bindings chainList.toml file") - // Write all chain configs to a single file type Superchain struct { Name string `toml:"name"` @@ -147,12 +140,13 @@ func main() { // Prepend an autogenerated header. header := []byte(`############################################## # DO NOT EDIT - THIS FILE IS AUTOGENERATED # +# DO NOT REMOVE - USED BY BINDINGS # ############################################## `) - // Write configs.toml file to the rust-bindings directory so it can be included in crate releases. + // Write configs.toml file to the top-level directory. buf = *bytes.NewBuffer(append(header, buf.Bytes()...)) - err = os.WriteFile(filepath.Join(repositoryRoot, "bindings/rust-bindings/etc/configs.toml"), buf.Bytes(), 0o644) + err = os.WriteFile(filepath.Join(repositoryRoot, "superchain/configs/configs.toml"), buf.Bytes(), 0o644) if err != nil { panic(err) } From a11045f5853423cfe265917d0652c36c8350e39a Mon Sep 17 00:00:00 2001 From: George Knee Date: Wed, 28 Aug 2024 16:46:11 +0100 Subject: [PATCH 09/30] update op-geth version (#523) to a commit on the main optimism branch --- add-chain/go.mod | 4 ++-- add-chain/go.sum | 4 ++-- validation/go.mod | 4 ++-- validation/go.sum | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/add-chain/go.mod b/add-chain/go.mod index 75447d3f2..ad03f5d70 100644 --- a/add-chain/go.mod +++ b/add-chain/go.mod @@ -4,12 +4,12 @@ go 1.21 replace github.com/ethereum-optimism/superchain-registry/superchain => ../superchain -replace github.com/ethereum/go-ethereum => github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240827194518-1071ac1284b8 +replace github.com/ethereum/go-ethereum => github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240828150145-60038121c757 require ( github.com/BurntSushi/toml v1.4.0 github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813 - github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240827194108-65ec82d9a1b2 + github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240828144951-4e6edcb7d36c github.com/ethereum/go-ethereum v1.14.7 github.com/google/go-cmp v0.6.0 github.com/joho/godotenv v1.5.1 diff --git a/add-chain/go.sum b/add-chain/go.sum index 7d7db161f..81c50f42a 100644 --- a/add-chain/go.sum +++ b/add-chain/go.sum @@ -61,8 +61,8 @@ github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5il github.com/decred/dcrd/crypto/blake256 v1.0.1/go.mod h1:2OfgNZ5wDpcsFmHmCK5gZTPcCXqlm2ArzUIkw9czNJo= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 h1:rpfIENRNNilwHwZeG5+P150SMrnNEcHYvcCuK6dPZSg= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= -github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240827194518-1071ac1284b8 h1:herYQxIOCZzBNAIClH0BP/+1BAXIn5bz0vRYH9bdgug= -github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240827194518-1071ac1284b8/go.mod h1:WBZxPjS4MTFLiFGEfBngof6KwdIU6zZ4t00B8zLJwDE= +github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240828150145-60038121c757 h1:egacojEWb68ew7vq0eyeOhM7XI2Soit/Xv1jXhVzRho= +github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240828150145-60038121c757/go.mod h1:boCyfYcCK/lDcL1JA5daLc2qgvULU1zKcVtUJ605eGc= github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813 h1:g1eUt4iB+v+FGdO7WAI17SpVahsrC6S9HGO0ceAd8Ec= github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813/go.mod h1:LTZIluX+26O0GHlwnFdPIUX04OUqcVDdThjRDsALYUY= github.com/ethereum/c-kzg-4844 v1.0.0 h1:0X1LBXxaEtYD9xsyj9B9ctQEZIpnvVDeoBx8aHEwTNA= diff --git a/validation/go.mod b/validation/go.mod index 8928b36f8..a752fc732 100644 --- a/validation/go.mod +++ b/validation/go.mod @@ -4,12 +4,12 @@ go 1.21 replace github.com/ethereum-optimism/superchain-registry/superchain => ../superchain -replace github.com/ethereum/go-ethereum => github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240827194518-1071ac1284b8 +replace github.com/ethereum/go-ethereum => github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240828150145-60038121c757 require ( github.com/BurntSushi/toml v1.4.0 github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813 - github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240827194108-65ec82d9a1b2 + github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240828144951-4e6edcb7d36c github.com/ethereum/go-ethereum v1.14.7 github.com/stretchr/testify v1.9.0 golang.org/x/mod v0.20.0 diff --git a/validation/go.sum b/validation/go.sum index 04afaa00a..b0fe537f4 100644 --- a/validation/go.sum +++ b/validation/go.sum @@ -61,8 +61,8 @@ github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5il github.com/decred/dcrd/crypto/blake256 v1.0.1/go.mod h1:2OfgNZ5wDpcsFmHmCK5gZTPcCXqlm2ArzUIkw9czNJo= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 h1:rpfIENRNNilwHwZeG5+P150SMrnNEcHYvcCuK6dPZSg= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= -github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240827194518-1071ac1284b8 h1:herYQxIOCZzBNAIClH0BP/+1BAXIn5bz0vRYH9bdgug= -github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240827194518-1071ac1284b8/go.mod h1:WBZxPjS4MTFLiFGEfBngof6KwdIU6zZ4t00B8zLJwDE= +github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240828150145-60038121c757 h1:egacojEWb68ew7vq0eyeOhM7XI2Soit/Xv1jXhVzRho= +github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240828150145-60038121c757/go.mod h1:boCyfYcCK/lDcL1JA5daLc2qgvULU1zKcVtUJ605eGc= github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813 h1:g1eUt4iB+v+FGdO7WAI17SpVahsrC6S9HGO0ceAd8Ec= github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813/go.mod h1:LTZIluX+26O0GHlwnFdPIUX04OUqcVDdThjRDsALYUY= github.com/ethereum/c-kzg-4844 v1.0.0 h1:0X1LBXxaEtYD9xsyj9B9ctQEZIpnvVDeoBx8aHEwTNA= From c48846ada62602384ac3e9da3a77ae95a59f475f Mon Sep 17 00:00:00 2001 From: George Knee Date: Wed, 28 Aug 2024 17:24:36 +0100 Subject: [PATCH 10/30] fix gas-token_test (#522) --- validation/gas-token_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/validation/gas-token_test.go b/validation/gas-token_test.go index 084f582cd..0d072f075 100644 --- a/validation/gas-token_test.go +++ b/validation/gas-token_test.go @@ -81,10 +81,10 @@ func getBool(method string, contractAddress Address, client *ethclient.Client) ( return false, err } - switch string(result) { - case "0x1": + switch common.HexToHash(string(result)) { + case common.Hash{1}: return true, nil - case "0x0": + case common.Hash{}: return false, nil default: return false, errors.New("unexpected non-bool return value") From 4ed0b20bc049e034686307810811184d8eb729d4 Mon Sep 17 00:00:00 2001 From: Tess Rinearson Date: Thu, 29 Aug 2024 16:52:57 +0200 Subject: [PATCH 11/30] tweak add-chain instructions (#528) --- docs/add-chain.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/add-chain.md b/docs/add-chain.md index 870b62199..af3cbb850 100644 --- a/docs/add-chain.md +++ b/docs/add-chain.md @@ -11,6 +11,8 @@ The following are the steps you need to take to add a chain to the registry: ### 0. Fork this repository You will be raising a Pull Request from your fork to the upstream repo. +We recommend only adding one chain at a time, and starting with a fresh branch of this repo for every chain. + ### 1. Install dependencies Install the following dependencies @@ -30,7 +32,7 @@ Make a copy of `.env.example` named `.env`, and alter the variables to appropria > [!IMPORTANT] > Adding a standard chain is a two-step process. For your initial PR, ensure > `SCR_STANDARD_CHAIN_CANDIDATE=true` in the `.env` file. After you've met all -> of the Standard chain requirements, you'll open a new PR following the +> of the [Standard chain requirements](./glossary.md), you'll open a new PR following the > [Promote a chain to standard](#promote-a-chain-to-standard) process. ### 3. Run script @@ -88,6 +90,7 @@ just codegen When opening a PR: - Open it from a non-protected branch in your fork (e.g. avoid the `main` branch). This allows maintainers to push to your branch if needed, which streamlines the review and merge process. - Open one PR per chain you would like to add. This ensures the merge of one chain is not blocked by unexpected issues. +- Once the PR is opened, please check the box to [allow edits from maintainers](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/allowing-changes-to-a-pull-request-branch-created-from-a-fork). Once the PR is opened, the same automated checks you've run locally will then run on your PR, and your PR will be reviewed in due course. Once these checks pass, the PR will be merged. From 936d40bcedb48fb695563d42b3112a33e88b6ac4 Mon Sep 17 00:00:00 2001 From: George Knee Date: Thu, 29 Aug 2024 16:57:36 +0100 Subject: [PATCH 12/30] Update README.md (#524) Remove link to bindings --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index 0477bd9f2..ce9257794 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,6 @@ The Superchain Registry is an index of chains which serves as the source of trut * ### [👀 See who's in the Superchain](chainList.json) * ### [⚙️ View detailed config information for each chain](superchain/configs) * ### [📝 Add a new chain to the Superchain Registry](docs/add-chain.md) -* ### [⛓️ Work with Superchain Registry Bindings](docs/bindings.md) ## More about the Superchain Registry From 70e9dbc1dcfe390b82d6170b3ef97547190aaf9d Mon Sep 17 00:00:00 2001 From: George Knee Date: Thu, 29 Aug 2024 23:11:51 +0100 Subject: [PATCH 13/30] add button with link to just-promotion-test slack message (#527) --- .circleci/config.yml | 49 ++++++++++++++++++++++++++------------------ 1 file changed, 29 insertions(+), 20 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 3dbe989ae..2d33833b5 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -131,29 +131,38 @@ jobs: - slack/notify: event: always custom: | - { - "blocks": [ - { - "type": "section", + { + "blocks": [ + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": ":control_knobs: The daily report on standard candidate chains is ready!" + }, + "accessory": { + "type": "button", "text": { + "type": "plain_text", + "text": "👀 View Report", + "emoji": true + }, + "url": "${CIRCLE_BUILD_URL}" + } + }, + { + "type": "divider" + }, + { + "type": "context", + "elements": [ + { "type": "mrkdwn", - "text": ":control_knobs: The daily report on standard candidate chains is ready!" + "text": "Click the link to see what validation checks would fail if all candidate chains were promoted to standard (and exclusions removed)." } - }, - { - "type": "divider" - }, - { - "type": "context", - "elements": [ - { - "type": "mrkdwn", - "text": "👀 Click the link to see what validation checks would fail if all candidate chains were promoted to standard (and exclusions removed)." - } - ] - } - ] - } + ] + } + ] + } channel: C07GZVCCUS0 # to slack channel `notify-superchain-promotion-failures` publish-bot: environment: From c7ac1442c4f431f96dff53cfc113ab120f7b672c Mon Sep 17 00:00:00 2001 From: cody-wang-cb Date: Fri, 30 Aug 2024 12:59:48 -0400 Subject: [PATCH 14/30] Update batcher proposer (#526) * update batcher proposer * ran codegen --------- Co-authored-by: George Knee --- superchain/configs/configs.toml | 6 +++--- superchain/configs/sepolia-dev-0/base-devnet-0.toml | 4 ++-- superchain/configs/sepolia/base.toml | 2 +- superchain/extra/addresses/addresses.json | 6 +++--- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/superchain/configs/configs.toml b/superchain/configs/configs.toml index 843a49c18..6d9546d2a 100644 --- a/superchain/configs/configs.toml +++ b/superchain/configs/configs.toml @@ -807,7 +807,7 @@ Challenger = "0xDa3037Ff70Ac92CD867c683BD807e5A484857405" Proposer = "0x20044a0d104E9e788A0C984A2B7eAe615afD046b" UnsafeBlockSigner = "0xb830b99c95Ea32300039624Cb567d324D4b1D83C" - BatchSubmitter = "0x6CDEbe940BC0F26850285cacA097C11c33103E47" + BatchSubmitter = "0xfc56E7272EEBBBA5bC6c544e159483C4a38f8bA3" AddressManager = "0x709c2B8ef4A9feFc629A8a2C1AF424Dc5BD6ad1B" L1CrossDomainMessengerProxy = "0xC34855F4De64F1840e5686e64278da901e261f20" L1ERC721BridgeProxy = "0x21eFD066e581FA55Ef105170Cc04d74386a09190" @@ -1065,9 +1065,9 @@ ProxyAdminOwner = "0xAf6E0E871f38c7B653700F7CbAEDafaa2784D430" Guardian = "0x4F43c7422a9b2AC4BC6145Bd4eE206EA73cF8266" Challenger = "0x5a533AaAC6cd81605b301a1077BC393A94658B6D" - Proposer = "0xBcB04FC753D36dcEeBe9Df7E18E23c46D1fcEA3c" + Proposer = "0xf99C2Da4822Af652fe1BF55F99713980efe5D261" UnsafeBlockSigner = "0xfd7bc3C58Fe4D4296F11F7843ebbA84D729A24B9" - BatchSubmitter = "0x212dD524932bC43478688F91045F2682913ad8EE" + BatchSubmitter = "0x7A43fD33e42054C965eE7175dd4590D2BDba79cB" AddressManager = "0x882a60911d00867Fe4ea632C479cc48e583A8D69" L1CrossDomainMessengerProxy = "0x2cbD403d5BA3949D24ee4dF57805eaC612C2662f" L1ERC721BridgeProxy = "0xc3016ED03E087d092d576B585F5222fFD9cadc10" diff --git a/superchain/configs/sepolia-dev-0/base-devnet-0.toml b/superchain/configs/sepolia-dev-0/base-devnet-0.toml index 98dd36a7c..8fa3cc67d 100644 --- a/superchain/configs/sepolia-dev-0/base-devnet-0.toml +++ b/superchain/configs/sepolia-dev-0/base-devnet-0.toml @@ -39,9 +39,9 @@ data_availability_type = "eth-da" ProxyAdminOwner = "0xAf6E0E871f38c7B653700F7CbAEDafaa2784D430" Guardian = "0x4F43c7422a9b2AC4BC6145Bd4eE206EA73cF8266" Challenger = "0x5a533AaAC6cd81605b301a1077BC393A94658B6D" - Proposer = "0xBcB04FC753D36dcEeBe9Df7E18E23c46D1fcEA3c" + Proposer = "0xf99C2Da4822Af652fe1BF55F99713980efe5D261" UnsafeBlockSigner = "0xfd7bc3C58Fe4D4296F11F7843ebbA84D729A24B9" - BatchSubmitter = "0x212dD524932bC43478688F91045F2682913ad8EE" + BatchSubmitter = "0x7A43fD33e42054C965eE7175dd4590D2BDba79cB" AddressManager = "0x882a60911d00867Fe4ea632C479cc48e583A8D69" L1CrossDomainMessengerProxy = "0x2cbD403d5BA3949D24ee4dF57805eaC612C2662f" L1ERC721BridgeProxy = "0xc3016ED03E087d092d576B585F5222fFD9cadc10" diff --git a/superchain/configs/sepolia/base.toml b/superchain/configs/sepolia/base.toml index 6b86c11ed..285b7b7ec 100644 --- a/superchain/configs/sepolia/base.toml +++ b/superchain/configs/sepolia/base.toml @@ -42,7 +42,7 @@ data_availability_type = "eth-da" Challenger = "0xDa3037Ff70Ac92CD867c683BD807e5A484857405" Proposer = "0x20044a0d104E9e788A0C984A2B7eAe615afD046b" UnsafeBlockSigner = "0xb830b99c95Ea32300039624Cb567d324D4b1D83C" - BatchSubmitter = "0x6CDEbe940BC0F26850285cacA097C11c33103E47" + BatchSubmitter = "0xfc56E7272EEBBBA5bC6c544e159483C4a38f8bA3" AddressManager = "0x709c2B8ef4A9feFc629A8a2C1AF424Dc5BD6ad1B" L1CrossDomainMessengerProxy = "0xC34855F4De64F1840e5686e64278da901e261f20" L1ERC721BridgeProxy = "0x21eFD066e581FA55Ef105170Cc04d74386a09190" diff --git a/superchain/extra/addresses/addresses.json b/superchain/extra/addresses/addresses.json index 6904bc5d6..23f413bfc 100644 --- a/superchain/extra/addresses/addresses.json +++ b/superchain/extra/addresses/addresses.json @@ -73,7 +73,7 @@ }, "11763072": { "AddressManager": "0x882a60911d00867Fe4ea632C479cc48e583A8D69", - "BatchSubmitter": "0x212dD524932bC43478688F91045F2682913ad8EE", + "BatchSubmitter": "0x7A43fD33e42054C965eE7175dd4590D2BDba79cB", "Challenger": "0x5a533AaAC6cd81605b301a1077BC393A94658B6D", "Guardian": "0x4F43c7422a9b2AC4BC6145Bd4eE206EA73cF8266", "L1CrossDomainMessengerProxy": "0x2cbD403d5BA3949D24ee4dF57805eaC612C2662f", @@ -82,7 +82,7 @@ "L2OutputOracleProxy": "0xB5901509329307E3f910f333Fa9C4B4A8EE7CE1A", "OptimismMintableERC20FactoryProxy": "0xEAa11178375e6B1078d815d6F9F85cBbb69b09Cd", "OptimismPortalProxy": "0x579c82A835B884336B632eeBeCC78FA08D3291Ec", - "Proposer": "0xBcB04FC753D36dcEeBe9Df7E18E23c46D1fcEA3c", + "Proposer": "0xf99C2Da4822Af652fe1BF55F99713980efe5D261", "ProxyAdmin": "0xC5aE9023bFA79124ffA50169E1423E733D0166f1", "ProxyAdminOwner": "0xAf6E0E871f38c7B653700F7CbAEDafaa2784D430", "SystemConfigOwner": "0xAf6E0E871f38c7B653700F7CbAEDafaa2784D430", @@ -260,7 +260,7 @@ "84532": { "AddressManager": "0x709c2B8ef4A9feFc629A8a2C1AF424Dc5BD6ad1B", "AnchorStateRegistryProxy": "0x4C8BA32A5DAC2A720bb35CeDB51D6B067D104205", - "BatchSubmitter": "0x6CDEbe940BC0F26850285cacA097C11c33103E47", + "BatchSubmitter": "0xfc56E7272EEBBBA5bC6c544e159483C4a38f8bA3", "Challenger": "0xDa3037Ff70Ac92CD867c683BD807e5A484857405", "DelayedWETHProxy": "0x7698b262B7a534912c8366dD8a531672deEC634e", "DisputeGameFactoryProxy": "0xd6E6dBf4F7EA0ac412fD8b65ED297e64BB7a06E1", From 852e7656419807dbe5d4b8eec175c821c8cf7f35 Mon Sep 17 00:00:00 2001 From: Sam Stokes <35908605+bitwiseguy@users.noreply.github.com> Date: Fri, 30 Aug 2024 14:26:23 -0400 Subject: [PATCH 15/30] validation: add Optimism Config test (#536) * validation: add Optimism Config test * validation: use string const for test names * validation: add explanatory comment for testOptimismConfig --- validation/exclusions_test.go | 18 +++++----- validation/rollup-config_test.go | 12 +++++++ validation/validation_test.go | 57 ++++++++++++++++++++++---------- 3 files changed, 61 insertions(+), 26 deletions(-) diff --git a/validation/exclusions_test.go b/validation/exclusions_test.go index 6c788156b..dae3ecffd 100644 --- a/validation/exclusions_test.go +++ b/validation/exclusions_test.go @@ -26,25 +26,25 @@ func skipIfExcluded(t *testing.T, chainID uint64) { var exclusions = map[string]map[uint64]bool{ // Universal Checks - "Genesis_Hash_Check": { + GenesisHashTest: { // OP Mainnet has a pre-bedrock genesis (with an empty allocs object stored in the registry), so we exclude it from this check.") 10: true, }, - "ChainID_RPC_Check": { + ChainIDRPCTest: { 11155421: true, // sepolia-dev-0/oplabs-devnet-0 No Public RPC declared 11763072: true, // sepolia-dev-0/base-devnet-0 No Public RPC declared }, - "Genesis_RPC_Check": { + GenesisRPCTest: { 11155421: true, // sepolia-dev-0/oplabs-devnet-0 No Public RPC declared 11763072: true, // sepolia-dev-0/base-devnet-0 No Public RPC declared }, - "Uniqueness_Check": { + UniquenessTest: { 11155421: true, // oplabs devnet 0, not in upstream repo 11763072: true, // base devnet 0, not in upstream repo} }, // Standard Checks - "L1_Security_Config": { + L1SecurityConfigTest: { 8453: true, // base (incorrect challenger, incorrect guardian) 84532: true, // base-sepolia (incorrect challenger) 7777777: true, // zora (incorrect challenger) @@ -54,17 +54,17 @@ var exclusions = map[string]map[uint64]bool{ 34443: true, // mode (incorrect challenger) 1740: true, // metal-sepolia }, - "Standard_Contract_Versions": { + StandardContractVersionsTest: { 11155421: true, // sepolia-dev0/oplabs-devnet-0 11763072: true, // sepolia-dev0/base-devnet-0 }, - "Optimism_Portal_2_Params": { + OptimismPortal2ParamsTest: { 11763072: true, // sepolia-dev0/base-devnet-0 }, } var silences = map[string]map[uint64]time.Time{ - "Optimism_Portal_2_Params": { + OptimismPortal2ParamsTest: { 10: time.Unix(int64(*superchain.OPChains[10].HardForkConfiguration.GraniteTime), 0), // mainnet/op silenced until Granite activates }, } @@ -72,7 +72,7 @@ var silences = map[string]map[uint64]time.Time{ func TestExclusions(t *testing.T) { for name, v := range exclusions { for k := range v { - if k == 10 && name == "Genesis_Hash_Check" { + if k == 10 && name == GenesisHashTest { // This is the sole standard chain validation check exclusion continue } diff --git a/validation/rollup-config_test.go b/validation/rollup-config_test.go index c954dc1f9..9eee4cf74 100644 --- a/validation/rollup-config_test.go +++ b/validation/rollup-config_test.go @@ -14,3 +14,15 @@ func testRollupConfig(t *testing.T, chain *ChainConfig) { assertIntInBounds(t, "Block Time", chain.BlockTime, standard.BlockTime) assertIntInBounds(t, "Sequencer Window Size", chain.SequencerWindowSize, standard.SequencerWindowSize) } + +// The values contained in the ChainConfig.Optimism struct used to be hardcoded within +// op-geth, not read from registry config files. This test forces chains that ran an +// old version of add-chain to include these fields, since they are now required downstream +func testOptimismConfig(t *testing.T, chain *ChainConfig) { + require.NotEmpty(t, chain.Optimism, "Optimism config cannot be nil") + require.NotEmpty(t, chain.Optimism.EIP1559Elasticity, "EIP1559Elasticity cannot be 0") + require.NotEmpty(t, chain.Optimism.EIP1559Denominator, "EIP1559Denominator cannot be 0") + if chain.CanyonTime != nil { + require.NotEmpty(t, chain.Optimism.EIP1559DenominatorCanyon, "EIP1559DenominatorCanyon cannot be 0 if canyon time is set") + } +} diff --git a/validation/validation_test.go b/validation/validation_test.go index 41ccdacd0..e065df9c0 100644 --- a/validation/validation_test.go +++ b/validation/validation_test.go @@ -6,6 +6,28 @@ import ( . "github.com/ethereum-optimism/superchain-registry/superchain" ) +// Test names +const ( + GenesisHashTest = "Genesis_Hash" + GenesisRPCTest = "Genesis_RPC" + UniquenessTest = "Uniqueness" + ChainIDRPCTest = "ChainID_RPC" + OptimismConfigTest = "Optimism_Config" + RollupConfigTest = "Rollup_Config" + GasTokenTest = "Gas_Token" + ResourceConfigTest = "Resource_Config" + GasLimitTest = "Gas_Limit" + GPOParamsTest = "GPO_Params" + StartBlockRPCTest = "Start_Block_RPC" + SuperchainConfigTest = "Superchain_Config" + L1SecurityConfigTest = "L1_Security_Config" + L2SecurityConfigTest = "L2_Security_Config" + DataAvailabilityTypeTest = "Data_Availability_Type" + StandardContractVersionsTest = "Standard_Contract_Versions" + OptimismPortal2ParamsTest = "Optimism_Portal_2_Params" + KeyHandoverTest = "Key_Handover" +) + func TestValidation(t *testing.T) { // Entry point for validation checks which run // on each OP chain. @@ -37,38 +59,39 @@ func testValidation(t *testing.T, chain *ChainConfig) { // designed to protect downstream software or // sanity checking basic consistency conditions. func testUniversal(t *testing.T, chain *ChainConfig) { - t.Run("Genesis Hash Check", func(t *testing.T) { testGenesisHash(t, chain.ChainID) }) - t.Run("Genesis RPC Check", func(t *testing.T) { testGenesisHashAgainstRPC(t, chain) }) - t.Run("Uniqueness Check", func(t *testing.T) { testIsGloballyUnique(t, chain) }) - t.Run("ChainID RPC Check", func(t *testing.T) { testChainIDFromRPC(t, chain) }) + t.Run(GenesisHashTest, func(t *testing.T) { testGenesisHash(t, chain.ChainID) }) + t.Run(GenesisRPCTest, func(t *testing.T) { testGenesisHashAgainstRPC(t, chain) }) + t.Run(UniquenessTest, func(t *testing.T) { testIsGloballyUnique(t, chain) }) + t.Run(ChainIDRPCTest, func(t *testing.T) { testChainIDFromRPC(t, chain) }) + t.Run(OptimismConfigTest, func(t *testing.T) { testOptimismConfig(t, chain) }) } // testStandardCandidate applies to Standard and Standard Candidate Chains. func testStandardCandidate(t *testing.T, chain *ChainConfig) { // Standard Config Params - t.Run("Rollup Config", func(t *testing.T) { testRollupConfig(t, chain) }) - t.Run("Gas Token", (func(t *testing.T) { testGasToken(t, chain) })) - t.Run("Resource Config", func(t *testing.T) { testResourceConfig(t, chain) }) - t.Run("Gas Limit", func(t *testing.T) { testGasLimit(t, chain) }) - t.Run("GPO Params", func(t *testing.T) { testGasPriceOracleParams(t, chain) }) - t.Run("Start Block RPC Check", func(t *testing.T) { testStartBlock(t, chain) }) - t.Run("Superchain Config", func(t *testing.T) { testSuperchainConfig(t, chain) }) + t.Run(RollupConfigTest, func(t *testing.T) { testRollupConfig(t, chain) }) + t.Run(GasTokenTest, func(t *testing.T) { testGasToken(t, chain) }) + t.Run(ResourceConfigTest, func(t *testing.T) { testResourceConfig(t, chain) }) + t.Run(GasLimitTest, func(t *testing.T) { testGasLimit(t, chain) }) + t.Run(GPOParamsTest, func(t *testing.T) { testGasPriceOracleParams(t, chain) }) + t.Run(StartBlockRPCTest, func(t *testing.T) { testStartBlock(t, chain) }) + t.Run(SuperchainConfigTest, func(t *testing.T) { testSuperchainConfig(t, chain) }) // Standard Config Roles - t.Run("L1 Security Config", func(t *testing.T) { testL1SecurityConfig(t, chain.ChainID) }) - t.Run("L2 Security Config", func(t *testing.T) { testL2SecurityConfig(t, chain) }) + t.Run(L1SecurityConfigTest, func(t *testing.T) { testL1SecurityConfig(t, chain.ChainID) }) + t.Run(L2SecurityConfigTest, func(t *testing.T) { testL2SecurityConfig(t, chain) }) // Other - t.Run("Data Availability Type", func(t *testing.T) { testDataAvailabilityType(t, chain) }) + t.Run(DataAvailabilityTypeTest, func(t *testing.T) { testDataAvailabilityType(t, chain) }) } // testStandard should be applied only to a fully Standard Chain, // i.e. not to a Standard Candidate Chain. func testStandard(t *testing.T, chain *ChainConfig) { // Standard Contract Versions - t.Run("Standard Contract Versions", func(t *testing.T) { + t.Run(StandardContractVersionsTest, func(t *testing.T) { testContractsMatchATag(t, chain) }) // Standard Config Params - t.Run("Optimism Portal 2 Params", func(t *testing.T) { testOptimismPortal2Params(t, chain) }) + t.Run(OptimismPortal2ParamsTest, func(t *testing.T) { testOptimismPortal2Params(t, chain) }) // Standard Config Roles - t.Run("Key Handover Check", func(t *testing.T) { testKeyHandover(t, chain.ChainID) }) + t.Run(KeyHandoverTest, func(t *testing.T) { testKeyHandover(t, chain.ChainID) }) } From fb639731dd3b7a94be73686199bad2b8d53dda23 Mon Sep 17 00:00:00 2001 From: George Knee Date: Fri, 30 Aug 2024 23:08:12 +0100 Subject: [PATCH 16/30] Use `op-contracts/v1.3.0` ABI for pre fault proofs validation (#537) * improve test failure output for testSuperchainConfig * use lowercase getters for nonFaultProofs standard roles this is the API for MCP release (1.3.0) * Update validation/superchain-config_test.go * just lint-all --- validation/security-configs_test.go | 2 +- validation/standard/standard-config-roles-mainnet.toml | 4 ++-- validation/standard/standard-config-roles-sepolia.toml | 4 ++-- .../standard/standard-config-roles-universal.toml | 10 +++++----- validation/superchain-config_test.go | 4 +++- 5 files changed, 13 insertions(+), 11 deletions(-) diff --git a/validation/security-configs_test.go b/validation/security-configs_test.go index 3e88d9799..d059dbd04 100644 --- a/validation/security-configs_test.go +++ b/validation/security-configs_test.go @@ -44,7 +44,7 @@ var checkResolutions = func(t *testing.T, r standard.Resolutions, chainID uint64 got, err := getAddress(method, contractAddress, client) require.NoErrorf(t, err, "problem calling %s.%s (%s)", contract, method, contractAddress) - // Use assert.True here for a concise output of failures, since failure info is sent to a slack channel + // Use t.Errorf here for a concise output of failures, since failure info is sent to a slack channel if want != got { t.Errorf("%s.%s = %s, expected %s (%s)", contract, method, got, want, output) } diff --git a/validation/standard/standard-config-roles-mainnet.toml b/validation/standard/standard-config-roles-mainnet.toml index 180d9e754..239a69ba6 100644 --- a/validation/standard/standard-config-roles-mainnet.toml +++ b/validation/standard/standard-config-roles-mainnet.toml @@ -1,6 +1,6 @@ [l1.nonFaultProofs] -OptimismPortalProxy."GUARDIAN()" = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" -L2OutputOracleProxy."CHALLENGER()" = "0x9BA6e03D8B90dE867373Db8cF1A58d2F7F006b3A" +OptimismPortalProxy."guardian()" = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" +L2OutputOracleProxy."challenger()" = "0x9BA6e03D8B90dE867373Db8cF1A58d2F7F006b3A" [l1.FaultProofs] OptimismPortalProxy."guardian()" = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" diff --git a/validation/standard/standard-config-roles-sepolia.toml b/validation/standard/standard-config-roles-sepolia.toml index 830e1b8a8..f3a1494e2 100644 --- a/validation/standard/standard-config-roles-sepolia.toml +++ b/validation/standard/standard-config-roles-sepolia.toml @@ -1,6 +1,6 @@ [l1.nonFaultProofs] -OptimismPortalProxy."GUARDIAN()" = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" -L2OutputOracleProxy."CHALLENGER()" = "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301" +OptimismPortalProxy."guardian()" = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" +L2OutputOracleProxy."challenger()" = "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301" [l1.FaultProofs] OptimismPortalProxy."guardian()" = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" diff --git a/validation/standard/standard-config-roles-universal.toml b/validation/standard/standard-config-roles-universal.toml index fc8e2b1ba..3ae8a3505 100644 --- a/validation/standard/standard-config-roles-universal.toml +++ b/validation/standard/standard-config-roles-universal.toml @@ -19,12 +19,12 @@ SystemConfigProxy."batcherHash()" = "BatchSubmitter" [l1.nonFaultProofs] -OptimismPortalProxy."GUARDIAN()" = "Guardian" -OptimismPortalProxy."SYSTEM_CONFIG()" = "SystemConfigProxy" -OptimismPortalProxy."L2_ORACLE()" = "L2OutputOracleProxy" +OptimismPortalProxy."guardian()" = "Guardian" +OptimismPortalProxy."systemConfig()" = "SystemConfigProxy" +OptimismPortalProxy."l2Oracle()" = "L2OutputOracleProxy" L2OutputOracleProxy."admin()" = "ProxyAdmin" -L2OutputOracleProxy."CHALLENGER()" = "Challenger" -L2OutputOracleProxy."PROPOSER()" = "Proposer" +L2OutputOracleProxy."challenger()" = "Challenger" +L2OutputOracleProxy."proposer()" = "Proposer" [l1.FaultProofs] DisputeGameFactoryProxy."admin()" = "ProxyAdmin" diff --git a/validation/superchain-config_test.go b/validation/superchain-config_test.go index 5cb0ecfd4..0157d1ce8 100644 --- a/validation/superchain-config_test.go +++ b/validation/superchain-config_test.go @@ -23,5 +23,7 @@ func testSuperchainConfig(t *testing.T, chain *ChainConfig) { got, err := getAddress("superchainConfig()", opp, client) require.NoError(t, err) - require.Equal(t, *expected, got) + if *expected != got { + t.Errorf("incorrect OptimismPortal.superchainConfig() address: got %s, wanted %s", got, *expected) + } } From 389619c58d77a312d2fb18fc342527886512c43c Mon Sep 17 00:00:00 2001 From: soyboy <85043086+sbvegan@users.noreply.github.com> Date: Mon, 2 Sep 2024 16:21:33 -0600 Subject: [PATCH 17/30] Update superchain.toml (#542) This timestamp is for Wednesday, not Tuesday https://www.epochconverter.com/ --- superchain/configs/mainnet/superchain.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/superchain/configs/mainnet/superchain.toml b/superchain/configs/mainnet/superchain.toml index 9b5f23a20..54e45406e 100644 --- a/superchain/configs/mainnet/superchain.toml +++ b/superchain/configs/mainnet/superchain.toml @@ -6,7 +6,7 @@ canyon_time = 1704992401 # Thu 11 Jan 2024 17:00:01 UTC delta_time = 1708560000 # Thu 22 Feb 2024 00:00:00 UTC ecotone_time = 1710374401 # Thu 14 Mar 2024 00:00:01 UTC fjord_time = 1720627201 # Wed 10 Jul 2024 16:00:01 UTC -granite_time = 1726070401 # Tue 11 Sep 2024 16:00:01 UTC +granite_time = 1726070401 # Wed 11 Sep 2024 16:00:01 UTC [l1] chain_id = 1 From 9c9ba657a4d26e1f80bada8e8e94a77df643018c Mon Sep 17 00:00:00 2001 From: George Knee Date: Tue, 3 Sep 2024 16:57:49 +0100 Subject: [PATCH 18/30] [ Feature Branch ] Genesis allocs validation (#489) * fix go.work version declaration * add genesis predeploy test, validation metadata for chains 10,34443 and wire up * undo accidental changes * fix ci config * add sepolia/worldcoin * add worldchain * some small fixes chain 480 passes! * change format of genesis creation command * add nvm * 4801 passes * introduce monorepoBuildCommand artifact * try removing source command * install nvm * no need to install just * linting * introduce boolean switch for using legacy deployments format * Get mode, metal and zora genesis.allocs validation working (#496) * introduce node_version need to reexamine writeDeploymentsLegacy * fix bug in writeDeploymentsLegacy * fix declaration of legacy deployments and add note * improve diff * use hardhat Deployment type to pad data and avoid unmarshaling errors e.g. on mode * fix writeDeploymentsLegacy, mode now validates! * remove note * introduce GenesisCreationCommand mapping allows metadata file to choose from a list and have chainId automatically injected into command * introduce BuilldCommand mapping * op sepolia validates * remove UseLegacyDeploymentsFormat * remove op mainnet metadata for now * remove op sepolia (it doesn't validate yet) * echo nvm version * just codegen * load nvm * fix * try installing nvm in a step * require node_version to be set * just lint-all * attempt to patch genesis creation source code to make validation work at a wider range of commits * adds metal metadata -- validates! * add zora metadata -- validates! * Enhance `add-chain` tool to capture deploy config and monorep commit information (#504) * add-chain: ingest and store deploy-config and genesis-creation commit * remove genesis-system-configs dir we no longer use this * add test data for deploy-config * check errs properly * link validation to add-chain * fix up add-chain e2e tests * simplify test side effect handling * don't bother cleaning up -test genesis validation inputs (They now don't end up bound into the validation package) * tweak spacing * prefer os.ModePerm over 0o777 * typo * typo * remove unused params * use commented constants for metadata defaults * fix clean-add-chain cmd * use localised, gitignored optimism-temporary directory for genesis validation purposes (#507) * Get genesis validation checks to run on CI (#529) * switch to cimg/go:1.22.6-node docker image for genesis validation * remove set -e (nvm.sh exits with code 3, we can apparently just ignore that) * use bash instead of sh * use . instead of source * install pnpm * move optimism-temporary out from under superchain-registry this seems to make go module resolution work as expected * do not allow validate-genesis to timeout * improve pipefail behaviour we allow the scripts which load nvm and gvm to fail * just lint-all * remove all set -e behaviour gives highest chance that validation can succeed * stream output from test helps with debugging, prevents timeouts on circleci * try running as a matrix * add base and base sepolia to genesis validation list (#530) * add base sepolia to genesis validation list * add base mainnet to genesis validation list * Add validation metadata for Lisk mainnet + testnet (#531) * temp: gk/genadd lisk mainnet (revertme) * add lisk metadata for genesis validation * temp: add lisk sepolia (revertme) * add genesis validation metadata for lisk sepolia * Update .circleci/config.yml * add comment * just tidy-all * harmonize op-geth version * improve naming of ci steps * dedupe perChainTestName * remove temporary directory after tests run * tidy up test script * rename test * rename commands * add testGenesisAllocsMetadata * use dynamic config building in CI (#534) * use dynamic config building in CI This works by having a small workflow run, compute the list of chain ids to run genesis validation checks on, and then modify a subsequent config file which circleci then runs. * add comment * fan in * fix * fix script * Update .circleci/continue_config.yml Co-authored-by: Vinod Damle --------- Co-authored-by: Vinod Damle * remove temporarily added chains (#535) * git restore --source=main -- superchain * just codegen * just lint-all * lint * typo * enhance comment * swap op-node1 and op-node2 to retain chronological ordering * add explainer about parallelism * modify message in genesis-allocs-all-ok * simplify patch file * tweak go version in golang-validate-genesis-allocs job * remove the test artifacts written to validationInputsDir * don't forget we swapped opnode1<>opnode2 * fix another opnode1<>opnode2 permutation * Revert "simplify patch file" This reverts commit 9b7f6d8bb00e417fd78e6a806390054402caaf08. * fix op-node1/2 err * add note about gvm --------- Co-authored-by: Vinod Damle --- .circleci/config.yml | 235 +-------------- .circleci/continue_config.yml | 279 ++++++++++++++++++ .env.example | 9 +- add-chain/e2e_test.go | 28 +- add-chain/flags/flags.go | 12 + add-chain/go.mod | 3 + add-chain/main.go | 62 +++- add-chain/testdata/.env.test | 2 + .../monorepo/deploy-config/sepolia.json | 41 +++ bindings/rust-bindings/etc/configs.toml | 112 +++++++ go.work | 2 +- justfile | 6 +- validation/.gitignore | 5 +- validation/common/common.go | 12 + validation/genesis-allocs_test.go | 23 ++ validation/genesis/commands.go | 49 +++ validation/genesis/config.patch | 13 + validation/genesis/foundry-config.patch | 13 + validation/genesis/genesis-allocs_test.go | 174 +++++++++++ validation/genesis/genesis.go | 63 ++++ validation/genesis/monorepo-outputs.sh | 24 ++ validation/genesis/utils.go | 151 ++++++++++ .../validation-inputs/1135/deploy-config.json | 59 ++++ .../genesis/validation-inputs/1135/meta.toml | 4 + .../validation-inputs/1750/deploy-config.json | 56 ++++ .../genesis/validation-inputs/1750/meta.toml | 4 + .../34443/deploy-config.json | 50 ++++ .../genesis/validation-inputs/34443/meta.toml | 4 + .../validation-inputs/4202/deploy-config.json | 46 +++ .../genesis/validation-inputs/4202/meta.toml | 4 + .../validation-inputs/480/deploy-config.json | 71 +++++ .../genesis/validation-inputs/480/meta.toml | 4 + .../validation-inputs/4801/deploy-config.json | 71 +++++ .../genesis/validation-inputs/4801/meta.toml | 4 + .../7777777/deploy-config.json | 43 +++ .../validation-inputs/7777777/meta.toml | 4 + .../validation-inputs/8453/deploy-config.json | 42 +++ .../genesis/validation-inputs/8453/meta.toml | 4 + .../84532/deploy-config.json | 44 +++ .../genesis/validation-inputs/84532/meta.toml | 4 + .../validation-inputs/generate-test-config.sh | 42 +++ validation/promotion_test.go | 3 +- validation/utils_test.go | 6 - validation/validation_test.go | 5 +- 44 files changed, 1654 insertions(+), 238 deletions(-) create mode 100644 .circleci/continue_config.yml create mode 100644 add-chain/testdata/monorepo/deploy-config/sepolia.json create mode 100644 validation/common/common.go create mode 100644 validation/genesis-allocs_test.go create mode 100644 validation/genesis/commands.go create mode 100644 validation/genesis/config.patch create mode 100644 validation/genesis/foundry-config.patch create mode 100644 validation/genesis/genesis-allocs_test.go create mode 100644 validation/genesis/genesis.go create mode 100755 validation/genesis/monorepo-outputs.sh create mode 100644 validation/genesis/utils.go create mode 100644 validation/genesis/validation-inputs/1135/deploy-config.json create mode 100644 validation/genesis/validation-inputs/1135/meta.toml create mode 100644 validation/genesis/validation-inputs/1750/deploy-config.json create mode 100644 validation/genesis/validation-inputs/1750/meta.toml create mode 100644 validation/genesis/validation-inputs/34443/deploy-config.json create mode 100644 validation/genesis/validation-inputs/34443/meta.toml create mode 100644 validation/genesis/validation-inputs/4202/deploy-config.json create mode 100644 validation/genesis/validation-inputs/4202/meta.toml create mode 100644 validation/genesis/validation-inputs/480/deploy-config.json create mode 100644 validation/genesis/validation-inputs/480/meta.toml create mode 100644 validation/genesis/validation-inputs/4801/deploy-config.json create mode 100644 validation/genesis/validation-inputs/4801/meta.toml create mode 100644 validation/genesis/validation-inputs/7777777/deploy-config.json create mode 100644 validation/genesis/validation-inputs/7777777/meta.toml create mode 100644 validation/genesis/validation-inputs/8453/deploy-config.json create mode 100644 validation/genesis/validation-inputs/8453/meta.toml create mode 100644 validation/genesis/validation-inputs/84532/deploy-config.json create mode 100644 validation/genesis/validation-inputs/84532/meta.toml create mode 100644 validation/genesis/validation-inputs/generate-test-config.sh diff --git a/.circleci/config.yml b/.circleci/config.yml index 2d33833b5..1c1dd63d1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,230 +1,27 @@ version: 2.1 -orbs: - go: circleci/go@1.8.0 - node: circleci/node@5.2.0 - slack: circleci/slack@4.10.1 - -commands: - notify-failures-on-main: - description: "Notify Slack for CI job failures" - parameters: - channel: - type: string - steps: - - slack/notify: - channel: << parameters.channel >> - event: fail - template: basic_fail_1 - branch_pattern: main - install-just: - description: "Install just" - steps: - - run: - name: "Install just" - command: | - wget -qO - 'https://proget.makedeb.org/debian-feeds/prebuilt-mpr.pub' | gpg --dearmor | sudo tee /usr/share/keyrings/prebuilt-mpr-archive-keyring.gpg 1> /dev/null - echo "deb [arch=all,$(dpkg --print-architecture) signed-by=/usr/share/keyrings/prebuilt-mpr-archive-keyring.gpg] https://proget.makedeb.org prebuilt-mpr $(lsb_release -cs)" | sudo tee /etc/apt/sources.list.d/prebuilt-mpr.list - sudo apt update - sudo apt install just - install-foundry: - description: "Installs foundry" - steps: - - run: - # need foundry to execute 'cast call' within add-chain script - name: Install foundry - command: | - echo "SHELL=$SHELL" - # Set up directory structure - mkdir -p $HOME/.foundry/bin - echo 'export PATH="$HOME/.foundry/bin:$PATH"' >> $BASH_ENV - source $BASH_ENV - - # Download foundryup and make it executable - curl -sSL "https://raw.githubusercontent.com/foundry-rs/foundry/master/foundryup/foundryup" -o $HOME/.foundry/bin/foundryup - chmod +x $HOME/.foundry/bin/foundryup +# this allows us to use CircleCI's dynamic configuration feature +setup: true - $HOME/.foundry/bin/foundryup - forge --version +orbs: + continuation: circleci/continuation@0.3.1 jobs: - golang-lint: - executor: - name: go/default # is based on cimg/go - tag: '1.21' - steps: - - checkout - - install-just - - run: just lint-all - - run: - name: check git tree is clean - command: git diff --exit-code - golang-modules-tidy: - executor: - name: go/default # is based on cimg/go - tag: '1.21' - steps: - - checkout - - install-just - - run: just tidy-all - - run: - name: check git tree is clean - command: git diff --exit-code - golang-test: - shell: /bin/bash -eo pipefail - executor: - name: go/default # is based on cimg/go - tag: '1.21' + setup-genesis-allocs-validation: + macos: + xcode: 14.2.0 + resource_class: macos.m1.medium.gen1 steps: - checkout - - install-just - - install-foundry - - run: - name: run superchain module unit tests - command: just test-superchain - run: - name: run validation module unit tests - command: just test-validation - - run: - name: run add-chain module unit tests - command: just test-add-chain - - notify-failures-on-main: - channel: C03N11M0BBN # to slack channel `notify-ci-failures` - golang-validate-modified: - shell: /bin/bash -eo pipefail - executor: - name: go/default # is based on cimg/go - tag: '1.21' - steps: - - checkout - - install-just - - install-foundry - - run: - name: run validation checks - command: just validate-modified-chains main # TODO ideally this is the base branch - golang-validate-all: - shell: /bin/bash -eo pipefail - executor: - name: go/default # is based on cimg/go - tag: '1.21' - steps: - - checkout - - install-just - - install-foundry - - run: - name: run validation checks on all chains - command: just validate "*" - - notify-failures-on-main: - channel: C07GQQZDW1G # to slack channel `notify-superchain-validation-failures` - golang-promotion-test: - shell: /bin/bash -eo pipefail - executor: - name: go/default # is based on cimg/go - tag: '1.21' - steps: - - checkout - - install-just - - install-foundry - - run: - name: run validation checks - command: just promotion-test - - slack/notify: - event: always - custom: | - { - "blocks": [ - { - "type": "section", - "text": { - "type": "mrkdwn", - "text": ":control_knobs: The daily report on standard candidate chains is ready!" - }, - "accessory": { - "type": "button", - "text": { - "type": "plain_text", - "text": "👀 View Report", - "emoji": true - }, - "url": "${CIRCLE_BUILD_URL}" - } - }, - { - "type": "divider" - }, - { - "type": "context", - "elements": [ - { - "type": "mrkdwn", - "text": "Click the link to see what validation checks would fail if all candidate chains were promoted to standard (and exclusions removed)." - } - ] - } - ] - } - channel: C07GZVCCUS0 # to slack channel `notify-superchain-promotion-failures` - publish-bot: - environment: - NODE_AUTH_TOKEN: $NPM_TOKEN # Use NPM_TOKEN as the auth token - docker: - - image: cimg/node:18 # Use Node.js 18 - steps: - - checkout - - run: - name: Set deployment token - command: npm config set '//registry.npmjs.org/:_authToken' "${NPM_TOKEN}" - - env: - NPM_TOKEN: ${{ secrets.NPM_TOKEN }} - - run: - name: Build and publish package on NPM 📦 - command: pnpm release - check-codegen: - executor: - name: go/default # is based on cimg/go - tag: '1.21' - steps: - - checkout - - install-just - - run: - name: Run codegen - command: just codegen - - run: - name: check git tree is clean - command: git diff --exit-code + name: Generate list of chainids and insert into continue_config.yml file + command: | + bash validation/genesis/validation-inputs/generate-test-config.sh + - continuation/continue: + configuration_path: .circleci/continue_config.yml + parameters: '{}' workflows: - hourly: - jobs: - - golang-validate-all: - context: - - slack - - golang-test: - context: - - slack - triggers: - - schedule: - cron: "0 * * * *" - filters: - branches: - only: - - main - nightly: - jobs: - - golang-promotion-test: - context: - - slack - triggers: - - schedule: - cron: "0 0 * * *" - filters: - branches: - only: - - main - pr-checks: + setup: jobs: - - golang-lint - - golang-modules-tidy - - golang-test - - golang-validate-modified - - check-codegen + - setup-genesis-allocs-validation diff --git a/.circleci/continue_config.yml b/.circleci/continue_config.yml new file mode 100644 index 000000000..21112a654 --- /dev/null +++ b/.circleci/continue_config.yml @@ -0,0 +1,279 @@ +version: 2.1 +orbs: + go: circleci/go@1.8.0 + node: circleci/node@5.2.0 + slack: circleci/slack@4.10.1 +commands: + notify-failures-on-main: + description: "Notify Slack for CI job failures" + parameters: + channel: + type: string + steps: + - slack/notify: + channel: << parameters.channel >> + event: fail + template: basic_fail_1 + branch_pattern: main + install-just: + steps: + - run: + name: "Install just" + command: | + wget -qO - 'https://proget.makedeb.org/debian-feeds/prebuilt-mpr.pub' | gpg --dearmor | sudo tee /usr/share/keyrings/prebuilt-mpr-archive-keyring.gpg 1> /dev/null + echo "deb [arch=all,$(dpkg --print-architecture) signed-by=/usr/share/keyrings/prebuilt-mpr-archive-keyring.gpg] https://proget.makedeb.org prebuilt-mpr $(lsb_release -cs)" | sudo tee /etc/apt/sources.list.d/prebuilt-mpr.list + sudo apt update + sudo apt install just + install-foundry: + steps: + - run: + # need foundry to execute 'cast call' within add-chain script + name: Install foundry + command: | + echo "SHELL=$SHELL" + # Set up directory structure + mkdir -p $HOME/.foundry/bin + echo 'export PATH="$HOME/.foundry/bin:$PATH"' >> $BASH_ENV + source $BASH_ENV + + # Download foundryup and make it executable + curl -sSL "https://raw.githubusercontent.com/foundry-rs/foundry/master/foundryup/foundryup" -o $HOME/.foundry/bin/foundryup + chmod +x $HOME/.foundry/bin/foundryup + + $HOME/.foundry/bin/foundryup + forge --version + install-gvm: + steps: + - run: + name: install gvm + command: | + sudo apt-get update + sudo apt-get -yq install curl git mercurial make binutils bison gcc build-essential bsdmainutils + bash < <(curl -s -S -L https://raw.githubusercontent.com/moovweb/gvm/master/binscripts/gvm-installer) + install-pnpm: + description: "Installs pnpm" + steps: + - run: + name: Install pnpm + command: | + sudo npm install -g pnpm + install-nvm: + description: "Installs nvm" + steps: + - run: + name: Install nvm + command: | + curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.4/install.sh | bash + export NVM_DIR="$HOME/.nvm" + [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm + source ~/.bashrc + nvm --version +jobs: + golang-lint: + executor: + name: go/default # is based on cimg/go + tag: '1.21' + steps: + - checkout + - install-just + - run: just lint-all + - run: + name: check git tree is clean + command: git diff --exit-code + golang-modules-tidy: + executor: + name: go/default # is based on cimg/go + tag: '1.21' + steps: + - checkout + - install-just + - run: just tidy-all + - run: + name: check git tree is clean + command: git diff --exit-code + golang-test: + shell: /bin/bash -eo pipefail + executor: + name: go/default # is based on cimg/go + tag: '1.21' + steps: + - checkout + - install-just + - install-foundry + - run: + name: run superchain module unit tests + command: just test-superchain + - run: + name: run validation module unit tests + command: just test-validation + - run: + name: run add-chain module unit tests + command: just test-add-chain + - notify-failures-on-main: + channel: C03N11M0BBN # to slack channel `notify-ci-failures` + # TODO this should also be filtered on modified chains + golang-validate-modified: + shell: /bin/bash -eo pipefail + executor: + name: go/default # is based on cimg/go + tag: '1.21' + steps: + - checkout + - install-just + - install-foundry + - run: + name: run validation checks + command: just validate-modified-chains main # TODO ideally this is the base branch + golang-validate-all: + shell: /bin/bash -eo pipefail + executor: + name: go/default # is based on cimg/go + tag: '1.21' + steps: + - checkout + - install-just + - install-foundry + - run: + name: run validation checks on all chains + command: just validate "*" + - notify-failures-on-main: + channel: C07GQQZDW1G # to slack channel `notify-superchain-validation-failures` + golang-promotion-test: + shell: /bin/bash -eo pipefail + executor: + name: go/default # is based on cimg/go + tag: '1.21' + steps: + - checkout + - install-just + - install-foundry + - run: + name: run validation checks + command: just promotion-test + - slack/notify: + event: always + custom: | + { + "blocks": [ + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": ":control_knobs: The daily report on standard candidate chains is ready!" + }, + "accessory": { + "type": "button", + "text": { + "type": "plain_text", + "text": "👀 View Report", + "emoji": true + }, + "url": "${CIRCLE_BUILD_URL}" + } + }, + { + "type": "divider" + }, + { + "type": "context", + "elements": [ + { + "type": "mrkdwn", + "text": "Click the link to see what validation checks would fail if all candidate chains were promoted to standard (and exclusions removed)." + } + ] + } + ] + } + channel: C07GZVCCUS0 # to slack channel `notify-superchain-promotion-reports` + publish-bot: + environment: + NODE_AUTH_TOKEN: $NPM_TOKEN # Use NPM_TOKEN as the auth token + docker: + - image: cimg/node:18 # Use Node.js 18 + steps: + - checkout + - run: + name: Set deployment token + command: npm config set '//registry.npmjs.org/:_authToken' "${NPM_TOKEN}" + - env: + NPM_TOKEN: ${{ secrets.NPM_TOKEN }} + - run: + name: "Build and publish package on NPM \U0001F4E6" + command: pnpm release + check-codegen: + executor: + name: go/default # is based on cimg/go + tag: '1.21' + steps: + - checkout + - install-just + - run: + name: Run codegen + command: just codegen + - run: + name: check git tree is clean + command: git diff --exit-code + golang-validate-genesis-allocs: + docker: + - image: cimg/go:1.21.12-node + resource_class: medium + parameters: + chainid: + type: string + steps: + - checkout + - install-pnpm + - install-just + - install-foundry + - install-gvm + - install-nvm + - run: just validate-genesis-allocs <> + genesis-allocs-all-ok: + docker: + - image: cimg/go:1.22.6-node + resource_class: medium + steps: + - checkout + - run: echo "All golang-validate-genesis-allocs jobs suceeded" +workflows: + hourly: + jobs: + - golang-validate-all: + context: + - slack + - golang-test: + context: + - slack + triggers: + - schedule: + cron: "0 * * * *" + filters: + branches: + only: + - main + nightly: + jobs: + - golang-promotion-test: + context: + - slack + triggers: + - schedule: + cron: "0 0 * * *" + filters: + branches: + only: + - main + pr-checks: + jobs: + - golang-validate-genesis-allocs: + matrix: + parameters: + chainid: [] # This list will be replaced by the generate_test_config.sh script + - genesis-allocs-all-ok: + requires: [] # This list will be replaced by the generate_test_config.sh script + - golang-lint + - golang-modules-tidy + - golang-test + - golang-validate-modified + - check-codegen diff --git a/.env.example b/.env.example index 6edb20be5..f2ba870ed 100644 --- a/.env.example +++ b/.env.example @@ -21,11 +21,18 @@ SCR_STANDARD_CHAIN_CANDIDATE=false # It is defined for convenience and reuse by other vars below SCR_MONOREPO_DIR=../optimism # path to local "ethereum-optimism/optimism" monorepo -# The following vars point to three input files required for adding a chain +# The following vars point to four input files required for adding a chain # Data will be scraped from these files in order to construct the required registry data +# and for genesis validation purposes. SCR_DEPLOYMENTS_DIR=${SCR_MONOREPO_DIR}/packages/contracts-bedrock/deployments/getting-started SCR_ROLLUP_CONFIG=${SCR_MONOREPO_DIR}/op-node/rollup.json SCR_GENESIS=${SCR_MONOREPO_DIR}/op-node/genesis.json +SCR_DEPLOY_CONFIG=${SCR_MONOREPO_DIR}/packages/contracts-bedrock/deploy-config/getting-started.json + +# This is the commit in the https://github.com/ethereum-optimism/optimism/ repo +# at which the chain's genesis was created. This is necessary to have our validation checks +# recreate the genesis file using identical source code +SCR_GENESIS_CREATION_COMMIT="" # Your chain's endpoint for ETHEREUM JSON-RPC requests SCR_PUBLIC_RPC="http://awe.some.rpc" # new OP Stack L2 RPC URL diff --git a/add-chain/e2e_test.go b/add-chain/e2e_test.go index 138ed2b71..0f2087160 100644 --- a/add-chain/e2e_test.go +++ b/add-chain/e2e_test.go @@ -1,7 +1,9 @@ package main import ( + "fmt" "os" + "path/filepath" "strconv" "testing" @@ -10,14 +12,15 @@ import ( ) const ( - addressDir = "../superchain/extra/addresses/sepolia/" - configDir = "../superchain/configs/sepolia/" - genesisSystemConfigDir = "../superchain/extra/genesis-system-configs/sepolia/" + addressDir = "../superchain/extra/addresses/sepolia/" + configDir = "../superchain/configs/sepolia/" + validationInputsDir = "../validation/genesis/validation-inputs" ) var tests = []struct { name string chainName string + chainId uint64 chainShortName string rollupConfigFile string standardChainCandidate bool @@ -27,6 +30,7 @@ var tests = []struct { { name: "baseline", chainName: "testchain_baseline", + chainId: 4206900, chainShortName: "testchain_b", rollupConfigFile: "./testdata/monorepo/op-node/rollup_baseline.json", deploymentsDir: "./testdata/monorepo/deployments", @@ -34,6 +38,7 @@ var tests = []struct { { name: "baseline_legacy", chainName: "testchain_baseline_legacy", + chainId: 4206905, chainShortName: "testchain_bl", rollupConfigFile: "./testdata/monorepo/op-node/rollup_baseline_legacy.json", deploymentsDir: "./testdata/monorepo/deployments-legacy", @@ -41,6 +46,7 @@ var tests = []struct { { name: "zorasep", chainName: "testchain_zorasep", + chainId: 4206904, chainShortName: "testchain_zs", rollupConfigFile: "./testdata/monorepo/op-node/rollup_zorasep.json", deploymentsDir: "./testdata/monorepo/deployments", @@ -49,6 +55,7 @@ var tests = []struct { { name: "altda", chainName: "testchain_altda", + chainId: 4206901, chainShortName: "testchain_ad", rollupConfigFile: "./testdata/monorepo/op-node/rollup_altda.json", deploymentsDir: "./testdata/monorepo/deployments", @@ -57,6 +64,7 @@ var tests = []struct { { name: "standard-candidate", chainName: "testchain_standard-candidate", + chainId: 4206902, chainShortName: "testchain_sc", rollupConfigFile: "./testdata/monorepo/op-node/rollup_standard-candidate.json", deploymentsDir: "./testdata/monorepo/deployments", @@ -65,6 +73,7 @@ var tests = []struct { { name: "faultproofs", chainName: "testchain_faultproofs", + chainId: 4206903, chainShortName: "testchain_fp", rollupConfigFile: "./testdata/monorepo/op-node/rollup_faultproofs.json", deploymentsDir: "./testdata/monorepo/deployments-faultproofs", @@ -78,7 +87,7 @@ func TestAddChain_Main(t *testing.T) { t.Run(tt.name, func(t *testing.T) { t.Parallel() - cleanupTestFiles(t, tt.chainShortName) + cleanupTestFiles(t, tt.chainShortName, tt.chainId) err := os.Setenv("SCR_RUN_TESTS", "true") require.NoError(t, err, "failed to set SCR_RUN_TESTS env var") @@ -169,10 +178,9 @@ func checkConfigTOML(t *testing.T, testName, chainShortName string) { require.Equal(t, string(expectedBytes), string(testBytes), "test .toml contents do not meet expectation") } -func cleanupTestFiles(t *testing.T, chainShortName string) { +func cleanupTestFiles(t *testing.T, chainShortName string, chainId uint64) { paths := []string{ addressDir + chainShortName + ".json", - genesisSystemConfigDir + chainShortName + ".json", configDir + chainShortName + ".toml", } @@ -182,5 +190,13 @@ func cleanupTestFiles(t *testing.T, chainShortName string) { t.Logf("Error removing file %s: %v\n", path, err) } } + + folderName := fmt.Sprintf("%d", chainId) + folderName = folderName + "-test" + genesisValidationInputs := filepath.Join(validationInputsDir, folderName) + err := os.RemoveAll(genesisValidationInputs) + if err != nil { + t.Logf("Error removing genesis validation inputs %s: %v\n", genesisValidationInputs, err) + } t.Logf("Removed test artifacts for chain: %s", chainShortName) } diff --git a/add-chain/flags/flags.go b/add-chain/flags/flags.go index 53fc057b9..ec127405e 100644 --- a/add-chain/flags/flags.go +++ b/add-chain/flags/flags.go @@ -70,6 +70,18 @@ var ( Usage: "Filepath to rollup.json input file", Required: true, } + DeployConfigFlag = &cli.StringFlag{ + Name: "deploy-config", + EnvVars: prefixEnvVars("DEPLOY_CONFIG"), + Usage: "Filepath to deploy-config json input file", + Required: true, + } + GenesisCreationCommit = &cli.StringFlag{ + Name: "genesis-creation-commit", + EnvVars: prefixEnvVars("GENESIS_CREATION_COMMIT"), + Usage: "Commit in the https://github.com/ethereum-optimism/optimism/ repo at which the chain's genesis was created", + Required: true, + } GenesisFlag = &cli.StringFlag{ Name: "genesis", EnvVars: prefixEnvVars("GENESIS"), diff --git a/add-chain/go.mod b/add-chain/go.mod index ad03f5d70..5a6ea0c57 100644 --- a/add-chain/go.mod +++ b/add-chain/go.mod @@ -6,10 +6,13 @@ replace github.com/ethereum-optimism/superchain-registry/superchain => ../superc replace github.com/ethereum/go-ethereum => github.com/ethereum-optimism/op-geth v1.101408.0-rc.4.0.20240828150145-60038121c757 +replace github.com/ethereum-optimism/superchain-registry/validation => ../validation + require ( github.com/BurntSushi/toml v1.4.0 github.com/ethereum-optimism/optimism v1.9.1-0.20240814195148-0bb2ff57c813 github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20240828144951-4e6edcb7d36c + github.com/ethereum-optimism/superchain-registry/validation v0.0.0-00010101000000-000000000000 github.com/ethereum/go-ethereum v1.14.7 github.com/google/go-cmp v0.6.0 github.com/joho/godotenv v1.5.1 diff --git a/add-chain/main.go b/add-chain/main.go index ea824db11..c7dfeaa93 100644 --- a/add-chain/main.go +++ b/add-chain/main.go @@ -3,16 +3,19 @@ package main import ( "fmt" "os" + "path" "path/filepath" "runtime" "strconv" "strings" + "github.com/BurntSushi/toml" "github.com/ethereum-optimism/optimism/op-e2e/bindings" "github.com/ethereum-optimism/superchain-registry/add-chain/cmd" "github.com/ethereum-optimism/superchain-registry/add-chain/config" "github.com/ethereum-optimism/superchain-registry/add-chain/flags" "github.com/ethereum-optimism/superchain-registry/superchain" + "github.com/ethereum-optimism/superchain-registry/validation/genesis" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/ethclient" @@ -35,6 +38,8 @@ var app = &cli.App{ flags.GenesisFlag, flags.DeploymentsDirFlag, flags.StandardChainCandidateFlag, + flags.GenesisCreationCommit, + flags.DeployConfigFlag, }, Action: entrypoint, Commands: []*cli.Command{ @@ -89,6 +94,8 @@ func entrypoint(ctx *cli.Context) error { chainName := ctx.String(flags.ChainNameFlag.Name) rollupConfigPath := ctx.String(flags.RollupConfigFlag.Name) genesisPath := ctx.String(flags.GenesisFlag.Name) + deployConfigPath := ctx.String(flags.DeployConfigFlag.Name) + genesisCreationCommit := ctx.String(flags.GenesisCreationCommit.Name) deploymentsDir := ctx.String(flags.DeploymentsDirFlag.Name) chainShortName := ctx.String(flags.ChainShortNameFlag.Name) if chainShortName == "" { @@ -110,6 +117,8 @@ func entrypoint(ctx *cli.Context) error { fmt.Printf("Deployments directory: %s\n", deploymentsDir) fmt.Printf("Rollup config filepath: %s\n", rollupConfigPath) fmt.Printf("Genesis filepath: %s\n", genesisPath) + fmt.Printf("Deploy config filepath: %s\n", deployConfigPath) + fmt.Printf("Genesis creation commit: %s\n", genesisCreationCommit) fmt.Printf("Public RPC endpoint: %s\n", publicRPC) fmt.Printf("Sequencer RPC endpoint: %s\n", sequencerRPC) fmt.Printf("Block Explorer: %s\n", explorer) @@ -169,7 +178,29 @@ func entrypoint(ctx *cli.Context) error { return fmt.Errorf("error generating chain config .yaml file: %w", err) } - fmt.Printf("Wrote config for new chain with identifier %s", rollupConfig.Identifier()) + fmt.Printf("✅ Wrote config for new chain with identifier %s", rollupConfig.Identifier()) + + folderName := fmt.Sprintf("%d", rollupConfig.ChainID) + if runningTests := os.Getenv("SCR_RUN_TESTS"); runningTests == "true" { + folderName = folderName + "-test" + } + genesisValidationInputsDir := filepath.Join(superchainRepoRoot, "validation", "genesis", "validation-inputs", folderName) + err = os.MkdirAll(genesisValidationInputsDir, os.ModePerm) + if err != nil { + return err + } + err = copyDeployConfigFile(deployConfigPath, genesisValidationInputsDir) + if err != nil { + return fmt.Errorf("error copying deploy-config json file: %w", err) + } + fmt.Printf("✅ Copied deploy-config json file to validation module") + + err = writeGenesisValidationMetadata(genesisCreationCommit, genesisValidationInputsDir) + if err != nil { + return fmt.Errorf("error writing genesis validation metadata file: %w", err) + } + fmt.Printf("✅ Wrote genesis validation metadata file") + return nil } @@ -230,3 +261,32 @@ func getGasPayingToken(l1rpcURl string, SystemConfigAddress superchain.Address) return (*superchain.Address)(&result.Addr), nil } + +func copyDeployConfigFile(sourcePath string, targetDir string) error { + data, err := os.ReadFile(sourcePath) + if err != nil { + return err + } + return os.WriteFile(path.Join(targetDir, "deploy-config.json"), data, os.ModePerm) +} + +func writeGenesisValidationMetadata(commit string, targetDir string) error { + // Define default metadata params: + // These may not be sufficient to make the genesis validation work, + // but we address that with some manual trial-and-error intervention + // involving OPLabs engineers after the add-chain command runs. + const defaultNodeVersion = "18.12.1" + const defaultMonorepoBuildCommand = "pnpm" + const defaultGenesisCreationCommand = "opnode2" // See validation/genesis/commands.go + vm := genesis.ValidationMetadata{ + GenesisCreationCommit: commit, + NodeVersion: defaultNodeVersion, + MonorepoBuildCommand: defaultMonorepoBuildCommand, + GenesisCreationCommand: defaultGenesisCreationCommand, + } + data, err := toml.Marshal(vm) + if err != nil { + return err + } + return os.WriteFile(path.Join(targetDir, "meta.toml"), data, os.ModePerm) +} diff --git a/add-chain/testdata/.env.test b/add-chain/testdata/.env.test index 0f92df81a..2703109b1 100644 --- a/add-chain/testdata/.env.test +++ b/add-chain/testdata/.env.test @@ -5,6 +5,8 @@ SCR_MONOREPO_DIR=./testdata/monorepo SCR_DEPLOYMENTS_DIR=${SCR_MONOREPO_DIR}/deployments SCR_ROLLUP_CONFIG=${SCR_MONOREPO_DIR}/op-node/rollup.json SCR_GENESIS=${SCR_MONOREPO_DIR}/op-node/genesis.json +SCR_GENESIS_CREATION_COMMIT=somecommit +SCR_DEPLOY_CONFIG=${SCR_MONOREPO_DIR}/deploy-config/sepolia.json SCR_PUBLIC_RPC="http://awe.some.rpc" # L2 RPC URL SCR_SEQUENCER_RPC="http://awe.some.seq.rpc" SCR_EXPLORER="https://awesomescan.org" # L2 block explorer URL diff --git a/add-chain/testdata/monorepo/deploy-config/sepolia.json b/add-chain/testdata/monorepo/deploy-config/sepolia.json new file mode 100644 index 000000000..bcc13611f --- /dev/null +++ b/add-chain/testdata/monorepo/deploy-config/sepolia.json @@ -0,0 +1,41 @@ +{ + "finalSystemOwner": "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301", + "portalGuardian": "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301", + "l1StartingBlockTag": "0x70e5634d09793b1cfaa7d0a2a5d3289a3b2308de1e82f682b4f817fc670f9797", + "l1ChainID": 11155111, + "l2ChainID": 11155420, + "l2BlockTime": 2, + "maxSequencerDrift": 600, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0x715b7219D986641DF9eFd9C7Ef01218D528e19ec", + "batchInboxAddress": "0xff00000000000000000000000000000011155420", + "batchSenderAddress": "0x7431310e026B69BFC676C0013E12A1A11411EEc9", + "l2OutputOracleSubmissionInterval": 120, + "l2OutputOracleStartingBlockNumber": 0, + "l2OutputOracleStartingTimestamp": 0, + "l2OutputOracleProposer": "0x02b1786A85Ec3f71fBbBa46507780dB7cF9014f6", + "l2OutputOracleChallenger": "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301", + "finalizationPeriodSeconds": 12, + "proxyAdminOwner": "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301", + "baseFeeVaultRecipient": "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301", + "l1FeeVaultRecipient": "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301", + "sequencerFeeVaultRecipient": "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301", + "baseFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "l1FeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "baseFeeVaultWithdrawalNetwork": 0, + "l1FeeVaultWithdrawalNetwork": 0, + "sequencerFeeVaultWithdrawalNetwork": 0, + "gasPriceOracleOverhead": 188, + "gasPriceOracleScalar": 684000, + "enableGovernance": true, + "governanceTokenSymbol": "OP", + "governanceTokenName": "Optimism", + "governanceTokenOwner": "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301", + "l2GenesisBlockGasLimit": "0x1c9c380", + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "eip1559Denominator": 50, + "eip1559Elasticity": 6, + "l2GenesisRegolithTimeOffset": "0x0" +} diff --git a/bindings/rust-bindings/etc/configs.toml b/bindings/rust-bindings/etc/configs.toml index 2ab7f8043..1e1177831 100644 --- a/bindings/rust-bindings/etc/configs.toml +++ b/bindings/rust-bindings/etc/configs.toml @@ -137,6 +137,62 @@ PreimageOracle = "0x0000000000000000000000000000000000000000" DAChallengeAddress = "0x0000000000000000000000000000000000000000" + [[superchains.chains]] + name = "World Chain" + chain_id = 480 + public_rpc = "https://worldchain-mainnet-sequencer.g.alchemy.com" + sequencer_rpc = "https://worldchain-mainnet-sequencer.g.alchemy.com" + explorer = "https://worldchain-mainnet-explorer.alchemy.com/" + superchain_level = 0 + standard_chain_candidate = true + batch_inbox_addr = "0xff00000000000000000000000000000000000480" + canyon_time = 0 + delta_time = 0 + ecotone_time = 0 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 1800 + data_availability_type = "eth-da" + [superchains.chains.genesis] + l2_time = 1719335639 + [superchains.chains.genesis.l1] + hash = "0x793daed4743301e00143be5533cd1dce0a741519e9e9c96588a9ad7dbb4d8db4" + number = 20170118 + [superchains.chains.genesis.l2] + hash = "0x70d316d2e0973b62332ba2e9768dd7854298d7ffe77f0409ffdb8d859f2d3fa3" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0xdBBE3D8c2d2b22A2611c5A94A9a12C2fCD49Eb29" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 100000000 + [superchains.chains.addresses] + SystemConfigOwner = "0xB2aa0C2C4fD6BFCBF699d4c787CD6Cc0dC461a9d" + ProxyAdminOwner = "0xA4fB12D15Eb85dc9284a7df0AdBC8B696EdbbF1d" + Guardian = "0xB2aa0C2C4fD6BFCBF699d4c787CD6Cc0dC461a9d" + Challenger = "0xB2aa0C2C4fD6BFCBF699d4c787CD6Cc0dC461a9d" + Proposer = "0x2307278fC8aB0005974A6DeD2FA6d1187333a223" + UnsafeBlockSigner = "0x2270d6eC8E760daA317DD978cFB98C8f144B1f3A" + BatchSubmitter = "0xdBBE3D8c2d2b22A2611c5A94A9a12C2fCD49Eb29" + AddressManager = "0x5891090d5085679714cb0e62f74950a3c19146a8" + L1CrossDomainMessengerProxy = "0xf931a81D18B1766d15695ffc7c1920a62b7e710a" + L1ERC721BridgeProxy = "0x1Df436AfDb2fBB40F1fE8bEd4Fc89A0D0990a8E9" + L1StandardBridgeProxy = "0x470458C91978D2d929704489Ad730DC3E3001113" + L2OutputOracleProxy = "0x19A6d1E9034596196295CF148509796978343c5D" + OptimismMintableERC20FactoryProxy = "0x82Cb528466cF22412d89bdBE9bCF04856790dD0e" + OptimismPortalProxy = "0xd5ec14a83B7d95BE1E2Ac12523e2dEE12Cbeea6C" + SystemConfigProxy = "0x6ab0777fD0e609CE58F939a7F70Fe41F5Aa6300A" + ProxyAdmin = "0xd7405BE7f3e63b094Af6C7C23D5eE33Fd82F872D" + SuperchainConfig = "0xa231f8be37e583f276f93dF516D88a043bfe47E3" + AnchorStateRegistryProxy = "0x1325C4966d17038C5592fb38416AeE85EE73c0cb" + DelayedWETHProxy = "0xF9adF7c9502C5C60352C20a4d22683422DbD061F" + DisputeGameFactoryProxy = "0x0E90dCAFBC242D2C861A20Bb20EC8E7182965a52" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0x267b2FFfA613c246Ef995390Ea0a2BaAA16a80Ba" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x3941778243E3E80a6a46D149F083825dEdc534BB" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + [[superchains.chains]] name = "Binary Mainnet" chain_id = 624 @@ -704,6 +760,62 @@ PreimageOracle = "0x0000000000000000000000000000000000000000" DAChallengeAddress = "0x0000000000000000000000000000000000000000" + [[superchains.chains]] + name = "World Chain Sepolia Testnet" + chain_id = 4801 + public_rpc = "" + sequencer_rpc = "https://worldchain-sepolia-sequencer.g.alchemy.com" + explorer = "https://worldchain-sepolia-explorer.alchemy.com/" + superchain_level = 0 + standard_chain_candidate = true + batch_inbox_addr = "0xFf00000000000000000000000000000000484752" + canyon_time = 0 + delta_time = 0 + ecotone_time = 0 + block_time = 2 + seq_window_size = 3600 + max_sequencer_drift = 1800 + data_availability_type = "eth-da" + [superchains.chains.genesis] + l2_time = 1720547424 + [superchains.chains.genesis.l1] + hash = "0xd220bbdf24df6d1611f4ece1d08c64feae914ce6299ab2806c864e30a5289201" + number = 6278018 + [superchains.chains.genesis.l2] + hash = "0xf1deb67ee953f94d8545d2647918687fa8ba1f30fa6103771f11b7c483984070" + number = 0 + [superchains.chains.genesis.system_config] + batcherAddress = "0x0f3ff4731D7a10B89ED79AD1Fd97844d7F66B96d" + overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" + scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" + gasLimit = 100000000 + [superchains.chains.addresses] + SystemConfigOwner = "0xe78a0A96C5D6aE6C606418ED4A9Ced378cb030A0" + ProxyAdminOwner = "0x945185C01fb641bA3E63a9bdF66575e35a407837" + Guardian = "0xe78a0A96C5D6aE6C606418ED4A9Ced378cb030A0" + Challenger = "0xe78a0A96C5D6aE6C606418ED4A9Ced378cb030A0" + Proposer = "0x77a95104e4025fC8B88A6a0F5FB7Fae20851E414" + UnsafeBlockSigner = "0x3241A7D28eA74E807A5087BA637fB58D8dDcd078" + BatchSubmitter = "0x0f3ff4731D7a10B89ED79AD1Fd97844d7F66B96d" + AddressManager = "0xc50Ba0767A1c0Ef69Cf1D9cd44De52b08589F691" + L1CrossDomainMessengerProxy = "0x7768c821200554d8F359A8902905Ba9eDe5659a9" + L1ERC721BridgeProxy = "0x3580505c56f8560E3777E92Fb27f70fD20c5B493" + L1StandardBridgeProxy = "0xd7DF54b3989855eb66497301a4aAEc33Dbb3F8DE" + L2OutputOracleProxy = "0xc8886f8BAb6Eaeb215aDB5f1c686BF699248300e" + OptimismMintableERC20FactoryProxy = "0x2D272eF54Ee8EF5c2Ff3523559186580b158cd57" + OptimismPortalProxy = "0xFf6EBa109271fe6d4237EeeD4bAb1dD9A77dD1A4" + SystemConfigProxy = "0x166F9406e79A656f12F05247fb8F5DfA6155bCBF" + ProxyAdmin = "0x3a987FE1cb587B0A1808cf9bB7Cbe0E341838319" + SuperchainConfig = "0x4642C5eD3B1568e0F05d73B10d02e6Fb2595aF9a" + AnchorStateRegistryProxy = "0x1517FDD5A31B35f790eA8a3c6cC2F595B1BD4742" + DelayedWETHProxy = "0x4F4B8Adf1af4b61bb62F68b7aF1c37f8A6311663" + DisputeGameFactoryProxy = "0x8cF97Ee616C986a070F5020d973b456D0120C253" + FaultDisputeGame = "0x0000000000000000000000000000000000000000" + MIPS = "0xCEd5c6ca2f32dE7bf43DB981E1cac398D7A978F2" + PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" + PreimageOracle = "0x954C0Fb8083047f37c8Fe954c114f8138614131C" + DAChallengeAddress = "0x0000000000000000000000000000000000000000" + [[superchains.chains]] name = "RACE Testnet" chain_id = 6806 diff --git a/go.work b/go.work index b7935e534..c0f7e3c67 100644 --- a/go.work +++ b/go.work @@ -1,4 +1,4 @@ -go 1.21.9 +go 1.21 use ( ./add-chain diff --git a/justfile b/justfile index a0171b29c..4730ad5fd 100644 --- a/justfile +++ b/justfile @@ -45,11 +45,14 @@ test-validation: clean-add-chain validate-modified-chains REF: # Running validation checks only for chains whose config has changed: git diff --merge-base {{REF}} --name-only 'superchain/configs/*.toml' ':(exclude)superchain/**/superchain.toml' | xargs -r awk '/chain_id/ {print $3}' | xargs -I {} just validate {} - # Run validation checks for chains with a name or chain ID matching the supplied regex, example: just validate 10 validate CHAIN_ID: TEST_DIRECTORY=./validation go run gotest.tools/gotestsum@latest --format testname -- -run='TestValidation/.+\({{CHAIN_ID}}\)$' -count=1 +# Run genesis validation (this is separated from other validation checks, because it is not a part of drift detection) +validate-genesis-allocs CHAIN_ID: + TEST_DIRECTORY=./validation/genesis go run gotest.tools/gotestsum@latest --format standard-verbose -- -run='TestGenesisAllocs/.+\({{CHAIN_ID}}\)$' -timeout 0 + promotion-test: TEST_DIRECTORY=./validation go run gotest.tools/gotestsum@latest --format dots -- -run Promotion @@ -57,6 +60,7 @@ promotion-test: clean-add-chain: rm -f superchain/configs/sepolia/testchain_*.toml rm -f superchain/extra/sepolia/testchain_*.json.gz + rm -rf -- validation/genesis/validation-inputs/*-test/ # Tidying all go.mod files tidy-all: tidy-add-chain tidy-superchain tidy-validation diff --git a/validation/.gitignore b/validation/.gitignore index 8d22a37f7..8a5e1f691 100644 --- a/validation/.gitignore +++ b/validation/.gitignore @@ -1,3 +1,6 @@ +# diff tool artifacts generate-rollup-config/output-* generate-genesis/output-* -genesis/optimism-temporary + +# test output artifacts +genesis/validation-inputs/*-test diff --git a/validation/common/common.go b/validation/common/common.go new file mode 100644 index 000000000..fdb5a7dc8 --- /dev/null +++ b/validation/common/common.go @@ -0,0 +1,12 @@ +package common + +import ( + "fmt" + + . "github.com/ethereum-optimism/superchain-registry/superchain" +) + +// PerChainTestName ensures test can easily be filtered by chain name or chain id using the -run=regex testflag. +func PerChainTestName(chain *ChainConfig) string { + return chain.Name + fmt.Sprintf(" (%d)", chain.ChainID) +} diff --git a/validation/genesis-allocs_test.go b/validation/genesis-allocs_test.go new file mode 100644 index 000000000..c189cfa16 --- /dev/null +++ b/validation/genesis-allocs_test.go @@ -0,0 +1,23 @@ +package validation + +import ( + "testing" + + . "github.com/ethereum-optimism/superchain-registry/superchain" + "github.com/ethereum-optimism/superchain-registry/validation/genesis" + "github.com/stretchr/testify/require" +) + +func testGenesisAllocsMetadata(t *testing.T, chain *ChainConfig) { + // This tests asserts that the a genesis creation commit is stored for + // the chain. It does not perform full genesis allocs validation. + // Full genesis allocs validation is run as a one-off requirement when + // chains are added to the registry and/or when the genesis creation commit itself + // is changed (and may be re-run at other choice moments). + // Therefore the presence of a genesis creation commit ensures that full genesis + // validation has been performed on this chain. + // This test is lightweight and can be run continually. + // The test tries to ensure that the information necessary + // for validating the genesis of the chain continues to exist over time. + require.NotEmpty(t, genesis.ValidationInputs[chain.ChainID].GenesisCreationCommit) +} diff --git a/validation/genesis/commands.go b/validation/genesis/commands.go new file mode 100644 index 000000000..c6843dfe2 --- /dev/null +++ b/validation/genesis/commands.go @@ -0,0 +1,49 @@ +package genesis + +import ( + "fmt" + "strings" +) + +type GeneratorFn func(uint64, string) string + +// GenesisCreationCommand stores various functions which return a +// command, encoded as a string, which can be used to generate the +// Genesis.allocs object at some historical commit or range of commits in the +// github.com/ethereum-optimism/optimism repo. For example, the command +// may be an op-node subcommand invocation, or a Foundry script invocation. +// The invocation has changed over time, including the format of the inputs +// specified in the command line arguments. +var GenesisCreationCommand = map[string]GeneratorFn{ + "opnode1": opnode1, + "opnode2": opnode2, +} + +func opnode1(chainId uint64, l1rpcURL string) string { + return strings.Join([]string{ + "go run op-node/cmd/main.go genesis l2", + fmt.Sprintf("--deploy-config=./packages/contracts-bedrock/deploy-config/%d.json", chainId), + "--outfile.l2=expected-genesis.json", + "--outfile.rollup=rollup.json", + fmt.Sprintf("--deployment-dir=./packages/contracts-bedrock/deployments/%d", chainId), + fmt.Sprintf("--l1-rpc=%s", l1rpcURL), + }, + " ") +} + +func opnode2(chainId uint64, l1rpcURL string) string { + return strings.Join([]string{ + "go run op-node/cmd/main.go genesis l2", + fmt.Sprintf(" --deploy-config=./packages/contracts-bedrock/deploy-config/%d.json", chainId), + "--outfile.l2=expected-genesis.json", + "--outfile.rollup=rollup.json", + fmt.Sprintf("--l1-deployments=./packages/contracts-bedrock/deployments/%d/.deploy", chainId), + fmt.Sprintf("--l1-rpc=%s", l1rpcURL), + }, + " ") +} + +var BuildCommand = map[string]string{ + "pnpm": "pnpm install --no-frozen-lockfile", + "yarn": "yarn install --no-frozen-lockfile", +} diff --git a/validation/genesis/config.patch b/validation/genesis/config.patch new file mode 100644 index 000000000..18c6f3eae --- /dev/null +++ b/validation/genesis/config.patch @@ -0,0 +1,13 @@ +diff --git a/op-chain-ops/genesis/config.go b/op-chain-ops/genesis/config.go +index 4c813acd4..42aa795ed 100644 +--- a/op-chain-ops/genesis/config.go ++++ b/op-chain-ops/genesis/config.go +@@ -588,7 +588,7 @@ func NewDeployConfig(path string) (*DeployConfig, error) { + } + + dec := json.NewDecoder(bytes.NewReader(file)) +- dec.DisallowUnknownFields() ++ // dec.DisallowUnknownFields() + + var config DeployConfig + if err := dec.Decode(&config); err != nil { diff --git a/validation/genesis/foundry-config.patch b/validation/genesis/foundry-config.patch new file mode 100644 index 000000000..dcdf635b8 --- /dev/null +++ b/validation/genesis/foundry-config.patch @@ -0,0 +1,13 @@ +diff --git a/packages/contracts-bedrock/foundry.toml b/packages/contracts-bedrock/foundry.toml +index 3d11af94b..c3d441735 100644 +--- a/packages/contracts-bedrock/foundry.toml ++++ b/packages/contracts-bedrock/foundry.toml +@@ -8,7 +8,7 @@ remappings = [ + '@openzeppelin/contracts-upgradeable/=node_modules/@openzeppelin/contracts-upgradeable/', + '@openzeppelin/contracts/=node_modules/@openzeppelin/contracts/', + '@rari-capital/solmate/=node_modules/@rari-capital/solmate', +- "@cwia/=node_modules/clones-with-immutable-args/src", ++ "@cwia/=node_modules/clones-with-immutable-args", + 'forge-std/=node_modules/forge-std/src', + 'ds-test/=node_modules/ds-test/src' + ] diff --git a/validation/genesis/genesis-allocs_test.go b/validation/genesis/genesis-allocs_test.go new file mode 100644 index 000000000..9b84bbf0c --- /dev/null +++ b/validation/genesis/genesis-allocs_test.go @@ -0,0 +1,174 @@ +package genesis + +import ( + "encoding/json" + "log" + "os" + "os/exec" + "path" + "path/filepath" + "runtime" + "strconv" + "testing" + + . "github.com/ethereum-optimism/superchain-registry/superchain" + . "github.com/ethereum-optimism/superchain-registry/validation/common" + + "github.com/ethereum/go-ethereum/core" + "github.com/stretchr/testify/require" +) + +var temporaryOptimismDir string + +// TestMain is the entry point for testing in this package. +func TestMain(m *testing.M) { + // Clone optimism into gitignored temporary directory (if that directory does not yet exist) + // We avoid cloning under the superchain-registry tree, since this causes dependency resolution problems + _, filename, _, ok := runtime.Caller(0) + if !ok { + panic("No caller information") + } + thisDir := filepath.Dir(filename) + temporaryOptimismDir = path.Join(thisDir, "../../../optimism-temporary") + + // Clone the repo if it the folder doesn't exist + _, err := os.Stat(temporaryOptimismDir) + needToClone := os.IsNotExist(err) + if needToClone { + mustExecuteCommandInDir(thisDir, + exec.Command("git", "clone", "https://github.com/ethereum-optimism/optimism.git", temporaryOptimismDir)) + } + + // Run tests + exitVal := m.Run() + + // Teardown code: + // Only if we cloned the directory, now delete it + // This means during local development, one can clone the + // repo manually before running the test to speed up runs. + if needToClone { + if err := os.RemoveAll(temporaryOptimismDir); err != nil { + panic("Failed to remove temp directory: " + err.Error()) + } + } + + // Exit with the result of the tests + os.Exit(exitVal) +} + +func TestGenesisAllocs(t *testing.T) { + for _, chain := range OPChains { + if chain.SuperchainLevel == Standard || chain.StandardChainCandidate { + t.Run(PerChainTestName(chain), func(t *testing.T) { + // Do not run in parallel, because + // the sub tests share the temporaryOptimismDir + // as a resource in a concurrency unsafe way. + // Parallelism is handled by the CI configuration. + testGenesisAllocs(t, chain) + }) + } + } +} + +func testGenesisAllocs(t *testing.T, chain *ChainConfig) { + chainId := chain.ChainID + vis, ok := ValidationInputs[chainId] + + if !ok { + t.Fatalf("Could not validate the genesis of chain %d (no validation metadata)", chainId) + } + + monorepoCommit := vis.GenesisCreationCommit + + // Setup some directory references + thisDir := getDirOfThisFile() + chainIdString := strconv.Itoa(int(chainId)) + validationInputsDir := path.Join(thisDir, "validation-inputs", chainIdString) + monorepoDir := temporaryOptimismDir + contractsDir := path.Join(monorepoDir, "packages/contracts-bedrock") + + // This is preferred to git checkout because it will + // blow away any leftover files from the previous run + t.Logf("🛠️ Resetting monorepo to %s...", monorepoCommit) + mustExecuteCommandInDir(monorepoDir, exec.Command("git", "reset", "--hard", monorepoCommit)) + + t.Log("🛠️ Deleting node_modules...") + mustExecuteCommandInDir(monorepoDir, exec.Command("rm", "-rf", "node_modules")) + mustExecuteCommandInDir(contractsDir, exec.Command("rm", "-rf", "node_modules")) + + t.Log("🛠️ Attempting to apply config.patch...") + mustExecuteCommandInDir(thisDir, exec.Command("cp", "config.patch", monorepoDir)) + _ = executeCommandInDir(monorepoDir, exec.Command("git", "apply", "config.patch")) // continue on error + + t.Log("🛠️ Copying deploy-config, deployments, and wrapper script to temporary dir...") + mustExecuteCommandInDir(validationInputsDir, + exec.Command("cp", "deploy-config.json", path.Join(contractsDir, "deploy-config", chainIdString+".json"))) + err := os.MkdirAll(path.Join(contractsDir, "deployments", chainIdString), os.ModePerm) + if err != nil { + log.Fatalf("Failed to create directory: %v", err) + } + if vis.GenesisCreationCommand == "opnode1" { + err = writeDeploymentsLegacy(chainId, path.Join(contractsDir, "deployments", chainIdString)) + } else { + err = writeDeployments(chainId, path.Join(contractsDir, "deployments", chainIdString)) + } + if err != nil { + log.Fatalf("Failed to write deployments: %v", err) + } + + mustExecuteCommandInDir(thisDir, exec.Command("cp", "./monorepo-outputs.sh", monorepoDir)) + buildCommand := BuildCommand[vis.MonorepoBuildCommand] + if vis.NodeVersion == "" { + panic("must set node_version in meta.toml") + } + creationCommand := GenesisCreationCommand[vis.GenesisCreationCommand](chainId, Superchains[chain.Superchain].Config.L1.PublicRPC) + cmd := exec.Command("bash", "./monorepo-outputs.sh", vis.NodeVersion, buildCommand, creationCommand) + + stdoutPipe, err := cmd.StdoutPipe() + if err != nil { + t.Fatalf("Failed to get stdout pipe: %v", err) + } + stderrPipe, err := cmd.StderrPipe() + if err != nil { + t.Fatalf("Failed to get stderr pipe: %v", err) + } + // Stream the command's stdout and stderr to the test logger + go streamOutputToLogger(stdoutPipe, t) + go streamOutputToLogger(stderrPipe, t) + + t.Log("🛠️ Regenerating genesis...") + mustExecuteCommandInDir(monorepoDir, cmd) + + t.Log("🛠️ Comparing registry genesis.alloc with regenerated genesis.alloc...") + expectedData, err := os.ReadFile(path.Join(monorepoDir, "expected-genesis.json")) + require.NoError(t, err) + + gen := core.Genesis{} + + err = json.Unmarshal(expectedData, &gen) + require.NoError(t, err) + + expectedData, err = json.MarshalIndent(gen.Alloc, "", " ") + require.NoError(t, err) + + g, err := core.LoadOPStackGenesis(chainId) + require.NoError(t, err) + + gotData, err := json.MarshalIndent(g.Alloc, "", " ") + require.NoError(t, err) + + err = os.WriteFile(path.Join(monorepoDir, "want-alloc.json"), expectedData, os.ModePerm) + require.NoError(t, err) + err = os.WriteFile(path.Join(monorepoDir, "got-alloc.json"), gotData, os.ModePerm) + require.NoError(t, err) + + require.Equal(t, string(expectedData), string(gotData)) +} + +func getDirOfThisFile() string { + _, filename, _, ok := runtime.Caller(0) + if !ok { + panic("No caller information") + } + return filepath.Dir(filename) +} diff --git a/validation/genesis/genesis.go b/validation/genesis/genesis.go new file mode 100644 index 000000000..04f8f859a --- /dev/null +++ b/validation/genesis/genesis.go @@ -0,0 +1,63 @@ +package genesis + +import ( + "embed" + "fmt" + "path" + "strconv" + "strings" + + "github.com/BurntSushi/toml" +) + +//go:embed validation-inputs +var validationInputs embed.FS + +var ValidationInputs map[uint64]ValidationMetadata + +func init() { + ValidationInputs = make(map[uint64]ValidationMetadata) + + chains, err := validationInputs.ReadDir("validation-inputs") + if err != nil { + panic(fmt.Errorf("failed to read validation-inputs dir: %w", err)) + } + // iterate over superchain-target entries + for _, s := range chains { + + if !s.IsDir() { + continue // ignore files, e.g. a readme + } + + // Load superchain-target config + metadata, err := validationInputs.ReadFile(path.Join("validation-inputs", s.Name(), "meta.toml")) + if err != nil { + panic(fmt.Errorf("failed to read metadata file: %w", err)) + } + + m := new(ValidationMetadata) + err = toml.Unmarshal(metadata, m) + if err != nil { + panic(fmt.Errorf("failed to decode metadata file: %w", err)) + } + + if strings.HasSuffix(s.Name(), "-test") { + continue + } + + chainID, err := strconv.Atoi(s.Name()) + if err != nil { + panic(fmt.Errorf("failed to decode chain id from dir name: %w", err)) + } + + ValidationInputs[uint64(chainID)] = *m + + } +} + +type ValidationMetadata struct { + GenesisCreationCommit string `toml:"genesis_creation_commit"` // in https://github.com/ethereum-optimism/optimism/ + NodeVersion string `toml:"node_version"` + MonorepoBuildCommand string `toml:"monorepo_build_command"` + GenesisCreationCommand string `toml:"genesis_creation_command"` +} diff --git a/validation/genesis/monorepo-outputs.sh b/validation/genesis/monorepo-outputs.sh new file mode 100755 index 000000000..b589bf18f --- /dev/null +++ b/validation/genesis/monorepo-outputs.sh @@ -0,0 +1,24 @@ +export NVM_DIR="$HOME/.nvm" +[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm + +echo "Installing and selecting correct Node version" +nvm install $1 +nvm use $1 + +echo "Running install command" +eval $2 + +echo "Installing and selecting correct go version" +go_version=$(grep -m 1 '^go ' go.mod | awk '{print $2}') + +# Source the gvm script to load gvm functions into the shell +# NOTE gvm is necessary because older versions of op-node used a +# library which is not compatible with newer versions of Go +# Running with go1.21 results in +# The version of quic-go you're using can't be built on Go 1.21 yet. For more details, please see https://github.com/quic-go/quic-go/wiki/quic-go-and-Go-versions." +. ~/.gvm/scripts/gvm +gvm install go${go_version} +gvm use go${go_version} + +echo "Running op-node genesis l2 command" +eval "$3" diff --git a/validation/genesis/utils.go b/validation/genesis/utils.go new file mode 100644 index 000000000..afef8272e --- /dev/null +++ b/validation/genesis/utils.go @@ -0,0 +1,151 @@ +package genesis + +import ( + "bufio" + "bytes" + "encoding/json" + "fmt" + "io" + "log" + "os" + "os/exec" + "path" + "strings" + "testing" + + . "github.com/ethereum-optimism/superchain-registry/superchain" + "github.com/ethereum/go-ethereum/common" +) + +func executeCommandInDir(dir string, cmd *exec.Cmd) error { + log.Printf("executing %s", cmd.String()) + cmd.Dir = dir + var outErr bytes.Buffer + cmd.Stdout = os.Stdout + cmd.Stderr = &outErr + err := cmd.Run() + if err != nil { + // error case : status code of command is different from 0 + fmt.Println(outErr.String()) + } + return err +} + +func mustExecuteCommandInDir(dir string, cmd *exec.Cmd) { + err := executeCommandInDir(dir, cmd) + if err != nil { + panic(err) + } +} + +func streamOutputToLogger(reader io.Reader, t *testing.T) { + scanner := bufio.NewScanner(reader) + for scanner.Scan() { + t.Log(scanner.Text()) + } + if err := scanner.Err(); err != nil { + t.Errorf("Error reading command output: %v", err) + } +} + +func writeDeployments(chainId uint64, directory string) error { + as := Addresses[chainId] + + data, err := json.Marshal(as) + if err != nil { + return err + } + + err = os.WriteFile(path.Join(directory, ".deploy"), data, os.ModePerm) + if err != nil { + return err + } + return nil +} + +func writeDeploymentsLegacy(chainId uint64, directory string) error { + // Prepare a HardHat Deployment type, we need this whole structure to make things + // work, although it is only the Address field which ends up getting used. + type StorageLayoutEntry struct { + AstId uint `json:"astId"` + Contract string `json:"contract"` + Label string `json:"label"` + Offset uint `json:"offset"` + Slot uint `json:"slot,string"` + Type string `json:"type"` + } + type StorageLayoutType struct { + Encoding string `json:"encoding"` + Label string `json:"label"` + NumberOfBytes uint `json:"numberOfBytes,string"` + Key string `json:"key,omitempty"` + Value string `json:"value,omitempty"` + Base string `json:"base,omitempty"` + } + type StorageLayout struct { + Storage []StorageLayoutEntry `json:"storage"` + Types map[string]StorageLayoutType `json:"types"` + } + type Deployment struct { + Name string + Abi []string `json:"abi"` + Address string `json:"address"` + Args []any `json:"args"` + Bytecode string `json:"bytecode"` + DeployedBytecode string `json:"deployedBytecode"` + Devdoc json.RawMessage `json:"devdoc"` + Metadata string `json:"metadata"` + Receipt json.RawMessage `json:"receipt"` + SolcInputHash string `json:"solcInputHash"` + StorageLayout StorageLayout `json:"storageLayout"` + TransactionHash common.Hash `json:"transactionHash"` + Userdoc json.RawMessage `json:"userdoc"` + } + + // Initialize your struct with some data + data := Addresses[chainId] + + type AddressList2 AddressList // use another type to prevent infinite recursion later on + b := AddressList2(*data) + + o, err := json.Marshal(b) + if err != nil { + return err + } + + out := make(map[string]Address) + err = json.Unmarshal(o, &out) + if err != nil { + return err + } + + for k, v := range out { + text, err := v.MarshalText() + if err != nil || !strings.HasPrefix(string(text), "0x") { + continue + } + // Define the Deployment object, filling in only what we need + jsonData := Deployment{Address: v.String(), Name: k} + + raw, err := json.MarshalIndent(jsonData, "", " ") + if err != nil { + return err + } + + fileName := fmt.Sprintf("%s.json", k) + file, err := os.Create(path.Join(directory, fileName)) + if err != nil { + return fmt.Errorf("failed to create file for field %s: %w", k, err) + } + defer file.Close() + + // Write the JSON content to the file + _, err = file.Write(raw) + if err != nil { + return fmt.Errorf("failed to write JSON to file for field %s: %w", k, err) + } + + fmt.Printf("Created file: %s\n", fileName) + } + return nil +} diff --git a/validation/genesis/validation-inputs/1135/deploy-config.json b/validation/genesis/validation-inputs/1135/deploy-config.json new file mode 100644 index 000000000..0324bd344 --- /dev/null +++ b/validation/genesis/validation-inputs/1135/deploy-config.json @@ -0,0 +1,59 @@ +{ + "l1ChainID": 1, + "l2ChainID": 1135, + "l2BlockTime": 2, + "maxSequencerDrift": 600, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0xb9DE90a90c5E441C483e754FE7341100D5fbaEcA", + "batchInboxAddress": "0xff00000000000000000000000000000000001135", + "batchSenderAddress": "0xa6Ea2f3299b63c53143c993d2d5E60A69Cd6Fe24", + "l1StartingBlockTag": "0xd580bdbd001908860f225c16ddaa08ada64471a68435694760c111253d97ffce", + "l2OutputOracleSubmissionInterval": 10800, + "l2OutputOracleStartingTimestamp": 1714728791, + "l2OutputOracleStartingBlockNumber": 0, + "l2OutputOracleProposer": "0x0AbD6da1cE10D1cD6c7C9C14b905786D20f3EB23", + "l2OutputOracleChallenger": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", + "l2GenesisBlockGasLimit": "0x1c9c380", + "l1BlockTime": 12, + "baseFeeVaultRecipient": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", + "l1FeeVaultRecipient": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", + "sequencerFeeVaultRecipient": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", + "baseFeeVaultMinimumWithdrawalAmount": "0x1bc16d674ec80000", + "l1FeeVaultMinimumWithdrawalAmount": "0x1bc16d674ec80000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0x1bc16d674ec80000", + "baseFeeVaultWithdrawalNetwork": 1, + "l1FeeVaultWithdrawalNetwork": 1, + "sequencerFeeVaultWithdrawalNetwork": 1, + "proxyAdminOwner": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", + "finalSystemOwner": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", + "superchainConfigGuardian": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", + "finalizationPeriodSeconds": 604800, + "fundDevAccounts": false, + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "gasPriceOracleOverhead": 188, + "gasPriceOracleScalar": 1000000, + "enableGovernance": false, + "governanceTokenSymbol": "OP", + "governanceTokenName": "Optimism", + "governanceTokenOwner": "0xdA6e5640aFB2ED212Ba3a6fd83076e2ad3daD185", + "eip1559Denominator": 1000, + "eip1559DenominatorCanyon": 1000, + "eip1559Elasticity": 20, + "l2GenesisRegolithTimeOffset": "0x0", + "l2GenesisDeltaTimeOffset": "0x0", + "l2GenesisCanyonTimeOffset": "0x0", + "l2GenesisEcotoneTimeOffset": "0x0", + "systemConfigStartBlock": 0, + "requiredProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", + "recommendedProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", + "faultGameAbsolutePrestate": "0x03cb5216c8cf2902c66127db119ba03a1296205736addc39cfeafc7c14d0bd14", + "faultGameMaxDepth": 73, + "faultGameMaxDuration": 604800, + "faultGameGenesisBlock": 0, + "faultGameGenesisOutputRoot": "0x0000000000000000000000000000000000000000000000000000000000000000", + "faultGameSplitDepth": 32, + "preimageOracleMinProposalSize": 1800000, + "preimageOracleChallengePeriod": 86400, + "l1CancunTimeOffset": "0x0" +} diff --git a/validation/genesis/validation-inputs/1135/meta.toml b/validation/genesis/validation-inputs/1135/meta.toml new file mode 100644 index 000000000..3b36e64e2 --- /dev/null +++ b/validation/genesis/validation-inputs/1135/meta.toml @@ -0,0 +1,4 @@ +genesis_creation_commit = "e6ef3a900c42c8722e72c2e2314027f85d12ced5" +monorepo_build_command = "pnpm" +node_version = "18.12.1" +genesis_creation_command = "opnode2" diff --git a/validation/genesis/validation-inputs/1750/deploy-config.json b/validation/genesis/validation-inputs/1750/deploy-config.json new file mode 100644 index 000000000..2b8347e78 --- /dev/null +++ b/validation/genesis/validation-inputs/1750/deploy-config.json @@ -0,0 +1,56 @@ +{ + "l1StartingBlockTag": "0x2493565ce8472656b7c22377c8d4d8ef5d17f78392c799ca5f2429b01e2c159c", + "l1ChainID": 1, + "l2ChainID": 1750, + "l2BlockTime": 2, + "l1BlockTime": 12, + "finalizationPeriodSeconds": 604800, + "systemConfigOwner": "0x4a4962275df8c60a80d3a25faec5aa7de116a746", + "finalSystemOwner": "0x4a4962275df8c60a80d3a25faec5aa7de116a746", + "controller": "0x87A1157dFCc065684DDE31fE202E50238A17Fc44", + "baseFeeVaultRecipient": "0x4a4962275df8c60a80d3a25faec5aa7de116a746", + "l1FeeVaultRecipient": "0x4a4962275df8c60a80d3a25faec5aa7de116a746", + "sequencerFeeVaultRecipient": "0x4a4962275df8c60a80d3a25faec5aa7de116a746", + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "governanceTokenOwner": "0x4a4962275df8c60a80d3a25faec5aa7de116a746", + "governanceTokenSymbol": "OP", + "governanceTokenName": "Optimism", + "maxSequencerDrift": 600, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0x4a65F5da5e80DEFfEA844eAa15CE130e80605dc5", + "optimismL2FeeRecipient": "0x3A2F5F909d7D3fb62E7Db3193df26078ec563795", + "batchInboxAddress": "0xc83f7D9F2D4A76E81145849381ABA02602373723", + "batchSenderAddress": "0xC94C243f8fb37223F3EB2f7961F7072602A51B8B", + "l2GenesisRegolithTimeOffset": "0x0", + "portalGuardian": "0x4a4962275df8c60a80d3a25faec5aa7de116a746", + "l2OutputOracleSubmissionInterval": 21600, + "l2OutputOracleStartingTimestamp": -1, + "l2OutputOracleStartingBlockNumber": 0, + "l2OutputOracleProposer": "0xC8187d40AD440328104A52BBed2D8Efc5ab1F1F6", + "l2OutputOracleOwner": "0x8768b38625c73FefC6036b4aAEA84483a23abE5D", + "sequencerFeeVaultWithdrawalNetwork": 0, + "baseFeeVaultWithdrawalNetwork": 0, + "l1FeeVaultWithdrawalNetwork": 0, + "baseFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "l1FeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "l2GenesisBlockGasLimit": "0x1c9c380", + "fundDevAccounts": false, + "gasPriceOracleOverhead": 188, + "gasPriceOracleScalar": 684000, + "eip1559Denominator": 50, + "eip1559Elasticity": 6, + "superchainConfigGuardian": "0x9BA6e03D8B90dE867373Db8cF1A58d2F7F006b3A", + "l2GenesisCanyonTimeOffset": "0x0", + "l2GenesisDeltaTimeOffset": "0x0", + "l2GenesisEcotoneTimeOffset": "0x0", + "eip1559DenominatorCanyon": 250, + "proxyAdmin": "0x72d29FD7601083E95e501Cc0DA7c9A9E073600a4", + "proxyAdminOwner": "0xefCf0c8faFB425997870f845e26fC6cA6EE6dD5C", + "optimismBaseFeeRecipient": "0x26F00eac2a7B0DE5D07109A10a284126F4667735", + "optimismL1FeeRecipient": "0x9c8c9743fD2632E0c22E309375D9c8e8A6d38c55", + "l2CrossDomainMessengerOwner": "0xcCf7200E0D99718C8efB9cD5fd4f95F67cf5E854", + "gasPriceOracleOwner": "0x155e6fb8e0f590a15F31a622D85a4cB42b9aB46E", + "l2OutputOracleChallenger": "0x4a4962275df8c60a80d3a25faec5aa7de116a746" +} diff --git a/validation/genesis/validation-inputs/1750/meta.toml b/validation/genesis/validation-inputs/1750/meta.toml new file mode 100644 index 000000000..0fcc1cd0b --- /dev/null +++ b/validation/genesis/validation-inputs/1750/meta.toml @@ -0,0 +1,4 @@ +genesis_creation_commit = "416cdccd2a93f83fe713dea3b0d86889c430dce3" +monorepo_build_command = "pnpm" +node_version = "18.12.1" +genesis_creation_command = "opnode2" diff --git a/validation/genesis/validation-inputs/34443/deploy-config.json b/validation/genesis/validation-inputs/34443/deploy-config.json new file mode 100644 index 000000000..9d105699c --- /dev/null +++ b/validation/genesis/validation-inputs/34443/deploy-config.json @@ -0,0 +1,50 @@ +{ + "l1StartingBlockTag": "0xf9b1b22a7ef9d13f063ea467bcb70fb6e9f29698ecb7366a2cdf5af2165cacee", + "l1ChainID": 1, + "l2ChainID": 34443, + "l2BlockTime": 2, + "finalizationPeriodSeconds": 604800, + "systemConfigOwner": "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746", + "finalSystemOwner": "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746", + "controller": "0xf4802485d882D8eEa73c8A07D7FaD3B20440f149", + "baseFeeVaultRecipient": "0xed4811010A86F7C39134fbC20206d906AD1176B6", + "l1FeeVaultRecipient": "0xed4811010A86F7C39134fbC20206d906AD1176B6", + "sequencerFeeVaultRecipient": "0xed4811010A86F7C39134fbC20206d906AD1176B6", + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "governanceTokenOwner": "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746", + "governanceTokenSymbol": "OP", + "governanceTokenName": "Optimism", + "maxSequencerDrift": 600, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0xa7fA9CA4ac88686A542C0f830d7378eAB4A0278F", + "optimismL2FeeRecipient": "0xB1498F5c779303Dc8A0A533197085ec77Faf9989", + "batchInboxAddress": "0x24E59d9d3Bd73ccC28Dc54062AF7EF7bFF58Bd67", + "batchSenderAddress": "0x99199a22125034c808ff20f377d91187E8050F2E", + "l2GenesisRegolithTimeOffset": "0x0", + "portalGuardian": "0x309Fe2536d01867018D120b40e4676723C53A14C", + "l2OutputOracleSubmissionInterval": 1800, + "l2OutputOracleStartingTimestamp": -1, + "l2OutputOracleStartingBlockNumber": "0x0", + "l2OutputOracleProposer": "0x674F64D64Ddc198db83cd9047dF54BF89cCD0ddB", + "l2OutputOracleOwner": "0x01409dB06A96EA7D10e81BcDD663D8bf745d2eab", + "sequencerFeeVaultWithdrawalNetwork": 0, + "baseFeeVaultWithdrawalNetwork": 0, + "l1FeeVaultWithdrawalNetwork": 0, + "baseFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "l1FeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "l2GenesisBlockGasLimit": "0x1c9c380", + "fundDevAccounts": false, + "gasPriceOracleOverhead": 188, + "gasPriceOracleScalar": 684000, + "eip1559Denominator": 50, + "eip1559Elasticity": 6, + "proxyAdmin": "0xEeeEe4060b1785Da25634449DdC57B44A40457e7", + "proxyAdminOwner": "0xefCf0c8faFB425997870f845e26fC6cA6EE6dD5C", + "optimismBaseFeeRecipient": "0x821DE76f548C46C1D8bf1821E3d177FfB234Ae9D", + "optimismL1FeeRecipient": "0x8BB4202D5e710fBFc6303b39532821eDC28E79d2", + "l2CrossDomainMessengerOwner": "0x17e3Dd82dE9e63614eeC3294640c286e0736F591", + "gasPriceOracleOwner": "0x3Bd5af32fedf8Dc1A9BB60420F2FF0d0368e34D1", + "l2OutputOracleChallenger": "0x309Fe2536d01867018D120b40e4676723C53A14C" +} diff --git a/validation/genesis/validation-inputs/34443/meta.toml b/validation/genesis/validation-inputs/34443/meta.toml new file mode 100644 index 000000000..a50912cd9 --- /dev/null +++ b/validation/genesis/validation-inputs/34443/meta.toml @@ -0,0 +1,4 @@ +genesis_creation_commit = "d80c145e0acf23a49c6a6588524f57e32e33b91" +monorepo_build_command = "pnpm" +node_version = "18.12.1" +genesis_creation_command = "opnode1" diff --git a/validation/genesis/validation-inputs/4202/deploy-config.json b/validation/genesis/validation-inputs/4202/deploy-config.json new file mode 100644 index 000000000..b17292dee --- /dev/null +++ b/validation/genesis/validation-inputs/4202/deploy-config.json @@ -0,0 +1,46 @@ +{ + "finalSystemOwner": "0x19De6D30Bf43654B7244B8adA135E1AA639bF091", + "superchainConfigGuardian": "0x19De6D30Bf43654B7244B8adA135E1AA639bF091", + "l1StartingBlockTag": "0x7d9d6dcec39efe182119f41b1bd2aa7b35b82e43927522afea86d210a4eace4b", + "l1ChainID": 11155111, + "l2ChainID": 4202, + "l2BlockTime": 2, + "l1BlockTime": 12, + "maxSequencerDrift": 600, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0x99804980804e9EbE78db89C049fFe36ceaaEF654", + "batchInboxAddress": "0xff00000000000000000000000000000000004202", + "batchSenderAddress": "0x246E119a5BcC2875161b23E4e602e25cEcE96E37", + "l2OutputOracleSubmissionInterval": 120, + "l2OutputOracleStartingBlockNumber": 0, + "l2OutputOracleStartingTimestamp": 1705312992, + "l2OutputOracleProposer": "0xBbD3a1D90B0Ef416581ACdC6a72046b38D3af9AD", + "l2OutputOracleChallenger": "0x19De6D30Bf43654B7244B8adA135E1AA639bF091", + "finalizationPeriodSeconds": 12, + "proxyAdminOwner": "0x19De6D30Bf43654B7244B8adA135E1AA639bF091", + "baseFeeVaultRecipient": "0x19De6D30Bf43654B7244B8adA135E1AA639bF091", + "l1FeeVaultRecipient": "0x19De6D30Bf43654B7244B8adA135E1AA639bF091", + "sequencerFeeVaultRecipient": "0x19De6D30Bf43654B7244B8adA135E1AA639bF091", + "baseFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "l1FeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "baseFeeVaultWithdrawalNetwork": 0, + "l1FeeVaultWithdrawalNetwork": 0, + "sequencerFeeVaultWithdrawalNetwork": 0, + "gasPriceOracleOverhead": 2100, + "gasPriceOracleScalar": 1000000, + "enableGovernance": true, + "governanceTokenSymbol": "OP", + "governanceTokenName": "Optimism", + "governanceTokenOwner": "0x19De6D30Bf43654B7244B8adA135E1AA639bF091", + "l2GenesisBlockGasLimit": "0x1c9c380", + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "l2GenesisRegolithTimeOffset": "0x0", + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250, + "eip1559Elasticity": 10, + "systemConfigStartBlock": 0, + "requiredProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", + "recommendedProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000" +} diff --git a/validation/genesis/validation-inputs/4202/meta.toml b/validation/genesis/validation-inputs/4202/meta.toml new file mode 100644 index 000000000..522a22adb --- /dev/null +++ b/validation/genesis/validation-inputs/4202/meta.toml @@ -0,0 +1,4 @@ +genesis_creation_commit = "28c359620f2b28238163eced79b39335d3a40661" +monorepo_build_command = "pnpm" +node_version = "18.12.1" +genesis_creation_command = "opnode2" diff --git a/validation/genesis/validation-inputs/480/deploy-config.json b/validation/genesis/validation-inputs/480/deploy-config.json new file mode 100644 index 000000000..cf44d86e3 --- /dev/null +++ b/validation/genesis/validation-inputs/480/deploy-config.json @@ -0,0 +1,71 @@ +{ + "finalSystemOwner": "0xb2aa0c2c4fd6bfcbf699d4c787cd6cc0dc461a9d", + "superchainConfigGuardian": "0xb2aa0c2c4fd6bfcbf699d4c787cd6cc0dc461a9d", + "proxyAdminOwner": "0xb2aa0c2c4fd6bfcbf699d4c787cd6cc0dc461a9d", + "l1StartingBlockTag": "0x793daed4743301e00143be5533cd1dce0a741519e9e9c96588a9ad7dbb4d8db4", + "l1ChainID": 1, + "l2ChainID": 480, + "l2BlockTime": 2, + "l1BlockTime": 12, + "maxSequencerDrift": 1800, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0x2270d6eC8E760daA317DD978cFB98C8f144B1f3A", + "batchInboxAddress": "0xff00000000000000000000000000000000000480", + "batchSenderAddress": "0xdbbe3d8c2d2b22a2611c5a94a9a12c2fcd49eb29", + "l2OutputOracleSubmissionInterval": 1800, + "l2OutputOracleStartingTimestamp": 1719335639, + "l2OutputOracleStartingBlockNumber": 0, + "gasPriceOracleOverhead": 188, + "gasPriceOracleScalar": 684000, + "gasPriceOracleBaseFeeScalar": 1368, + "gasPriceOracleBlobBaseFeeScalar": 810949, + "l2GenesisCanyonTimeOffset": "0x0", + "l2GenesisDeltaTimeOffset": "0x0", + "l2GenesisEcotoneTimeOffset": "0x0", + "l2OutputOracleProposer": "0x2307278fc8ab0005974a6ded2fa6d1187333a223", + "l2OutputOracleChallenger": "0xb2aa0c2c4fd6bfcbf699d4c787cd6cc0dc461a9d", + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "l2GenesisBlockGasLimit": "0x5f5e100", + "baseFeeVaultRecipient": "0xb2aa0c2c4fd6bfcbf699d4c787cd6cc0dc461a9d", + "l1FeeVaultRecipient": "0xb2aa0c2c4fd6bfcbf699d4c787cd6cc0dc461a9d", + "sequencerFeeVaultRecipient": "0xb2aa0c2c4fd6bfcbf699d4c787cd6cc0dc461a9d", + "baseFeeVaultMinimumWithdrawalAmount": "0x2386f26fc10000", + "l1FeeVaultMinimumWithdrawalAmount": "0x2386f26fc10000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0x2386f26fc10000", + "baseFeeVaultWithdrawalNetwork": 0, + "l1FeeVaultWithdrawalNetwork": 0, + "sequencerFeeVaultWithdrawalNetwork": 0, + "enableGovernance": true, + "governanceTokenName": "Optimism", + "governanceTokenSymbol": "OP", + "governanceTokenOwner": "0x9965507D1a55bcC2695C58ba16FB37d819B0A4dc", + "finalizationPeriodSeconds": 604800, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250, + "eip1559Elasticity": 10, + "l2GenesisRegolithTimeOffset": "0x0", + "systemConfigStartBlock": 0, + "requiredProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", + "recommendedProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", + "faultGameAbsolutePrestate": "0x0000000000000000000000000000000000000000000000000000000000000000", + "faultGameMaxDepth": 1, + "faultGameGenesisBlock": 0, + "faultGameGenesisOutputRoot": "0xDEADBEEFDEADBEEFDEADBEEFDEADBEEFDEADBEEFDEADBEEFDEADBEEFDEADBEEF", + "faultGameSplitDepth": 0, + "faultGameWithdrawalDelay": 0, + "faultGameClockExtension": 0, + "faultGameMaxClockDuration": 0, + "preimageOracleMinProposalSize": 0, + "preimageOracleChallengePeriod": 0, + "proofMaturityDelaySeconds": 604800, + "disputeGameFinalityDelaySeconds": 302400, + "respectedGameType": 0, + "useFaultProofs": false, + "fundDevAccounts": false, + "usePlasma": false, + "daChallengeWindow": 0, + "daResolveWindow": 0, + "daBondSize": 0, + "daResolverRefundPercentage": 0 +} diff --git a/validation/genesis/validation-inputs/480/meta.toml b/validation/genesis/validation-inputs/480/meta.toml new file mode 100644 index 000000000..2eb23c53a --- /dev/null +++ b/validation/genesis/validation-inputs/480/meta.toml @@ -0,0 +1,4 @@ +genesis_creation_commit = "4a3d3fb444f50bed6a6991785ea5634e0efa07a4" +monorepo_build_command = "pnpm" +node_version = "18.12.1" +genesis_creation_command = "opnode2" diff --git a/validation/genesis/validation-inputs/4801/deploy-config.json b/validation/genesis/validation-inputs/4801/deploy-config.json new file mode 100644 index 000000000..f501b77a9 --- /dev/null +++ b/validation/genesis/validation-inputs/4801/deploy-config.json @@ -0,0 +1,71 @@ +{ + "finalSystemOwner": "0xe78a0a96c5d6ae6c606418ed4a9ced378cb030a0", + "superchainConfigGuardian": "0xe78a0a96c5d6ae6c606418ed4a9ced378cb030a0", + "proxyAdminOwner": "0xe78a0a96c5d6ae6c606418ed4a9ced378cb030a0", + "l1StartingBlockTag": "0xd220bbdf24df6d1611f4ece1d08c64feae914ce6299ab2806c864e30a5289201", + "l1ChainID": 11155111, + "l2ChainID": 4801, + "l2BlockTime": 2, + "l1BlockTime": 12, + "maxSequencerDrift": 1800, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0x3241A7D28eA74E807A5087BA637fB58D8dDcd078", + "batchInboxAddress": "0xff00000000000000000000000000000000484752", + "batchSenderAddress": "0x0f3ff4731d7a10b89ed79ad1fd97844d7f66b96d", + "l2OutputOracleSubmissionInterval": 1800, + "l2OutputOracleStartingTimestamp": 1720547424, + "l2OutputOracleStartingBlockNumber": 0, + "gasPriceOracleOverhead": 188, + "gasPriceOracleScalar": 684000, + "gasPriceOracleBaseFeeScalar": 1368, + "gasPriceOracleBlobBaseFeeScalar": 810949, + "l2GenesisCanyonTimeOffset": "0x0", + "l2GenesisDeltaTimeOffset": "0x0", + "l2GenesisEcotoneTimeOffset": "0x0", + "l2OutputOracleProposer": "0x77a95104e4025fc8b88a6a0f5fb7fae20851e414", + "l2OutputOracleChallenger": "0xe78a0a96c5d6ae6c606418ed4a9ced378cb030a0", + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "l2GenesisBlockGasLimit": "0x5f5e100", + "baseFeeVaultRecipient": "0xe78a0a96c5d6ae6c606418ed4a9ced378cb030a0", + "l1FeeVaultRecipient": "0xe78a0a96c5d6ae6c606418ed4a9ced378cb030a0", + "sequencerFeeVaultRecipient": "0xe78a0a96c5d6ae6c606418ed4a9ced378cb030a0", + "baseFeeVaultMinimumWithdrawalAmount": "0x2386f26fc10000", + "l1FeeVaultMinimumWithdrawalAmount": "0x2386f26fc10000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0x2386f26fc10000", + "baseFeeVaultWithdrawalNetwork": 0, + "l1FeeVaultWithdrawalNetwork": 0, + "sequencerFeeVaultWithdrawalNetwork": 0, + "enableGovernance": true, + "governanceTokenName": "Optimism", + "governanceTokenSymbol": "OP", + "governanceTokenOwner": "0x9965507D1a55bcC2695C58ba16FB37d819B0A4dc", + "finalizationPeriodSeconds": 12, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250, + "eip1559Elasticity": 10, + "l2GenesisRegolithTimeOffset": "0x0", + "systemConfigStartBlock": 0, + "requiredProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", + "recommendedProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", + "faultGameAbsolutePrestate": "0x0000000000000000000000000000000000000000000000000000000000000000", + "faultGameMaxDepth": 1, + "faultGameGenesisBlock": 0, + "faultGameGenesisOutputRoot": "0xDEADBEEFDEADBEEFDEADBEEFDEADBEEFDEADBEEFDEADBEEFDEADBEEFDEADBEEF", + "faultGameSplitDepth": 0, + "faultGameWithdrawalDelay": 0, + "faultGameClockExtension": 0, + "faultGameMaxClockDuration": 0, + "preimageOracleMinProposalSize": 0, + "preimageOracleChallengePeriod": 0, + "proofMaturityDelaySeconds": 604800, + "disputeGameFinalityDelaySeconds": 302400, + "respectedGameType": 0, + "useFaultProofs": false, + "fundDevAccounts": false, + "usePlasma": false, + "daChallengeWindow": 0, + "daResolveWindow": 0, + "daBondSize": 0, + "daResolverRefundPercentage": 0 +} diff --git a/validation/genesis/validation-inputs/4801/meta.toml b/validation/genesis/validation-inputs/4801/meta.toml new file mode 100644 index 000000000..2eb23c53a --- /dev/null +++ b/validation/genesis/validation-inputs/4801/meta.toml @@ -0,0 +1,4 @@ +genesis_creation_commit = "4a3d3fb444f50bed6a6991785ea5634e0efa07a4" +monorepo_build_command = "pnpm" +node_version = "18.12.1" +genesis_creation_command = "opnode2" diff --git a/validation/genesis/validation-inputs/7777777/deploy-config.json b/validation/genesis/validation-inputs/7777777/deploy-config.json new file mode 100644 index 000000000..7b670c6a8 --- /dev/null +++ b/validation/genesis/validation-inputs/7777777/deploy-config.json @@ -0,0 +1,43 @@ +{ + "l1StartingBlockTag": "0x10aa183", + "l1ChainID": 1, + "l2ChainID": 7777777, + "l2BlockTime": 2, + "finalizationPeriodSeconds": 604800, + "systemConfigOwner": "0xC72aE5c7cc9a332699305E29F68Be66c73b60542", + "finalSystemOwner": "0xC72aE5c7cc9a332699305E29F68Be66c73b60542", + "controller": "0xEe729F57F0111FD0F660867d0F522f983202a5aF", + "baseFeeVaultRecipient": "0xe900b3Edc1BA0430CFa9a204A1027B90825ac951", + "l1FeeVaultRecipient": "0xe900b3Edc1BA0430CFa9a204A1027B90825ac951", + "sequencerFeeVaultRecipient": "0xe900b3Edc1BA0430CFa9a204A1027B90825ac951", + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "governanceTokenOwner": "0xC72aE5c7cc9a332699305E29F68Be66c73b60542", + "governanceTokenSymbol": "OP", + "governanceTokenName": "Optimism", + "maxSequencerDrift": 600, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0x3Dc8Dfd0709C835cAd15a6A27e089FF4cF4C9228", + "optimismL2FeeRecipient": "0x63AA492609175d1824dD668BDadF0042E74b0fC8", + "batchInboxAddress": "0x6F54Ca6F6EdE96662024Ffd61BFd18f3f4e34DFf", + "batchSenderAddress": "0x625726c858dBF78c0125436C943Bf4b4bE9d9033", + "l2GenesisRegolithTimeOffset": "0x0", + "portalGuardian": "0xC72aE5c7cc9a332699305E29F68Be66c73b60542", + "l2OutputOracleSubmissionInterval": 180, + "l2OutputOracleStartingTimestamp": -1, + "l2OutputOracleProposer": "0x48247032092e7b0ecf5dEF611ad89eaf3fC888Dd", + "l2OutputOracleOwner": "0xDA1F62857EA7f10444725c6c435235243D623540", + "l2GenesisBlockGasLimit": "0x1c9c380", + "fundDevAccounts": false, + "gasPriceOracleOverhead": 188, + "gasPriceOracleScalar": 684000, + "eip1559Denominator": 50, + "eip1559Elasticity": 6, + "proxyAdmin": "0x027860cA56cF779371461C14c3a483c94e1aA8a0", + "proxyAdminOwner": "0xb0cCdbD6fe09D2199171BE19450aF249250518A0", + "optimismBaseFeeRecipient": "0xea4591A6e5a31CF0b822A4f563163CeeBeEe4eb1", + "optimismL1FeeRecipient": "0xdD7aCF916c3E3Fb959CA3bB29beFffcAD2e90be6", + "l2CrossDomainMessengerOwner": "0xA53EF9bBec25fdA4b6Da7EF5617565794369A2A5", + "gasPriceOracleOwner": "0x9c3651E0B3CE47A0b17d775077E3d9B712582be0", + "l2OutputOracleChallenger": "0xcA4571b1ecBeC86Ea2E660d242c1c29FcB55Dc72" +} diff --git a/validation/genesis/validation-inputs/7777777/meta.toml b/validation/genesis/validation-inputs/7777777/meta.toml new file mode 100644 index 000000000..b3ffa8e64 --- /dev/null +++ b/validation/genesis/validation-inputs/7777777/meta.toml @@ -0,0 +1,4 @@ +genesis_creation_commit = "65ec61dde94ffa93342728d324fecf474d228e1f" +monorepo_build_command = "pnpm" +node_version = "18.12.1" +genesis_creation_command = "opnode1" diff --git a/validation/genesis/validation-inputs/8453/deploy-config.json b/validation/genesis/validation-inputs/8453/deploy-config.json new file mode 100644 index 000000000..6b24a04ab --- /dev/null +++ b/validation/genesis/validation-inputs/8453/deploy-config.json @@ -0,0 +1,42 @@ +{ + "numDeployConfirmations": 1, + "finalSystemOwner": "0x9855054731540A48b28990B63DcF4f33d8AE46A1", + "portalGuardian": "0x14536667Cd30e52C0b458BaACcB9faDA7046E056", + "controller": "0x6606d3c20cc94cc7aa1d430c0e83a5129976153a", + "l1StartingBlockTag": "0x5c13d307623a926cd31415036c8b7fa14572f9dac64528e857a470511fc30771", + "l2GenesisBlockExtraData": "YWxsIHlvdXIgYmFzZSBhcmUgYmVsb25nIHRvIHlvdS4=", + "l1ChainID": 1, + "l2ChainID": 8453, + "l2BlockTime": 2, + "maxSequencerDrift": 600, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0xAf6E19BE0F9cE7f8afd49a1824851023A8249e8a", + "batchInboxAddress": "0xFf00000000000000000000000000000000008453", + "batchSenderAddress": "0x5050F69a9786F081509234F1a7F4684b5E5b76C9", + "l2OutputOracleSubmissionInterval": 1800, + "l2OutputOracleStartingBlockNumber": 0, + "l2OutputOracleStartingTimestamp": 1686789348, + "l2OutputOracleProposer": "0x642229f238fb9dE03374Be34B0eD8D9De80752c5", + "l2OutputOracleChallenger": "0x14536667Cd30e52C0b458BaACcB9faDA7046E056", + "finalizationPeriodSeconds": 604800, + "proxyAdminOwner": "0x76A737DAC0c4eB926bd7d2D68b958A1ae6Ad6993", + "baseFeeVaultRecipient": "0x09C7bAD99688a55a2e83644BFAed09e62bDcCcBA", + "l1FeeVaultRecipient": "0x09C7bAD99688a55a2e83644BFAed09e62bDcCcBA", + "sequencerFeeVaultRecipient": "0x09C7bAD99688a55a2e83644BFAed09e62bDcCcBA", + "baseFeeVaultMinimumWithdrawalAmount": "0x1bc16d674ec80000", + "l1FeeVaultMinimumWithdrawalAmount": "0x1bc16d674ec80000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0x1bc16d674ec80000", + "baseFeeVaultWithdrawalNetwork": 1, + "l1FeeVaultWithdrawalNetwork": 1, + "sequencerFeeVaultWithdrawalNetwork": 1, + "gasPriceOracleOverhead": 188, + "gasPriceOracleScalar": 684000, + "l2GenesisBlockGasLimit": "0x1c9c380", + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "l2GenesisBlockCoinbase": "0x4200000000000000000000000000000000000011", + "enableGovernance": false, + "eip1559Denominator": 50, + "eip1559Elasticity": 6, + "l2GenesisRegolithTimeOffset": "0x0" +} diff --git a/validation/genesis/validation-inputs/8453/meta.toml b/validation/genesis/validation-inputs/8453/meta.toml new file mode 100644 index 000000000..6af6d48ed --- /dev/null +++ b/validation/genesis/validation-inputs/8453/meta.toml @@ -0,0 +1,4 @@ +genesis_creation_commit = "a541c8a859d9258ad410598655f189de69adae19" +monorepo_build_command = "pnpm" +node_version = "18.12.1" +genesis_creation_command = "opnode1" diff --git a/validation/genesis/validation-inputs/84532/deploy-config.json b/validation/genesis/validation-inputs/84532/deploy-config.json new file mode 100644 index 000000000..6a9fe2bdf --- /dev/null +++ b/validation/genesis/validation-inputs/84532/deploy-config.json @@ -0,0 +1,44 @@ +{ + "finalSystemOwner": "0x608081689Fe46936fB2fBDF7552CbB1D80ad4822", + "portalGuardian": "0xA9FF930151130fd19DA1F03E5077AFB7C78F8503", + "l1StartingBlockTag": "0xcac9a83291d4dec146d6f7f69ab2304f23f5be87b1789119a0c5b1e4482444ed", + "l1ChainID": 11155111, + "l2ChainID": 84532, + "l1BlockTime": 12, + "l2BlockTime": 2, + "maxSequencerDrift": 600, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0xb830b99c95Ea32300039624Cb567d324D4b1D83C", + "batchInboxAddress": "0xFf00000000000000000000000000000000084532", + "batchSenderAddress": "0x6CDEbe940BC0F26850285cacA097C11c33103E47", + "l2OutputOracleSubmissionInterval": 120, + "l2OutputOracleStartingBlockNumber": 0, + "l2OutputOracleStartingTimestamp": -1, + "l2OutputOracleProposer": "0x20044a0d104E9e788A0C984A2B7eAe615afD046b", + "l2OutputOracleChallenger": "0xDa3037Ff70Ac92CD867c683BD807e5A484857405", + "finalizationPeriodSeconds": 12, + "proxyAdminOwner": "0x8937037a0bB08658e5A178C182e60b12f14720ce", + "baseFeeVaultRecipient": "0xc7dE632EC7f11634318856a57c5897f6a0bda3b0", + "l1FeeVaultRecipient": "0x9082AB367EAFe8887a88A1B9970BE2719007Cf6b", + "sequencerFeeVaultRecipient": "0x4cFDfb25b34b5e5E3932dA5C4F080194137AF20F", + "baseFeeVaultMinimumWithdrawalAmount": "0x1bc16d674ec80000", + "l1FeeVaultMinimumWithdrawalAmount": "0x1bc16d674ec80000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0x1bc16d674ec80000", + "baseFeeVaultWithdrawalNetwork": 0, + "l1FeeVaultWithdrawalNetwork": 0, + "sequencerFeeVaultWithdrawalNetwork": 0, + "gasPriceOracleOverhead": 2100, + "gasPriceOracleScalar": 1000000, + "governanceTokenSymbol": "NA", + "governanceTokenName": "NotApplicable", + "governanceTokenOwner": "0xEb5E931176714636563DC7BE4A10387D911BaE05", + "l2GenesisBlockGasLimit": "0x17D7840", + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "eip1559Denominator": 50, + "eip1559Elasticity": 10, + "l2GenesisRegolithTimeOffset": "0x0", + "systemConfigStartBlock": 0, + "requiredProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", + "recommendedProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000" +} diff --git a/validation/genesis/validation-inputs/84532/meta.toml b/validation/genesis/validation-inputs/84532/meta.toml new file mode 100644 index 000000000..5bbc4c517 --- /dev/null +++ b/validation/genesis/validation-inputs/84532/meta.toml @@ -0,0 +1,4 @@ +genesis_creation_commit = "a7ff5a811612fa338d0a6d6dd72dc2ec9badef6d" +monorepo_build_command = "pnpm" +node_version = "18.12.1" +genesis_creation_command = "opnode1" diff --git a/validation/genesis/validation-inputs/generate-test-config.sh b/validation/genesis/validation-inputs/generate-test-config.sh new file mode 100644 index 000000000..0ae4dbfc3 --- /dev/null +++ b/validation/genesis/validation-inputs/generate-test-config.sh @@ -0,0 +1,42 @@ +#!/usr/bin/env bash +set -o errexit -o pipefail +set -x + +# Get the list of changed files +targetList=$(git diff --name-only --merge-base main -- validation/genesis/*.toml) + +# Check if targetList is empty +if [ -z "$targetList" ]; then + echo "No matching .toml files found in 'validation/genesis/'. Exiting." + exit 0 +fi + +# Process the targetList to extract directory names and then the base names +targetList=$(echo "$targetList" | xargs dirname | xargs basename) + +# Join the array elements with commas and wrap each element in quotes +targets=$(echo "$targetList" | sed 's/.*/"&"/' | tr '\n' ',') + +# Remove the trailing comma +targets=${targets%,} + +# Wrap in square brackets +targets="[$targets]" + +echo "Will run genesis allocs validation on chains with ids $targets" + +# Now build another array, each element prepended with "golang-validate-genesis-allocs-" +prependedTargets=$(echo "$targetList" | sed 's/.*/"golang-validate-genesis-allocs-&"/' | tr '\n' ',') + +# Remove the trailing comma +prependedTargets=${prependedTargets%,} + +# Wrap in square brackets +prependedTargets="[$prependedTargets]" + +# Install yq +brew install yq + +# Use yq to replace the target-version key +yq e ".workflows.pr-checks.jobs[0].golang-validate-genesis-allocs.matrix.parameters.chainid = $targets" -i .circleci/continue_config.yml +yq e ".workflows.pr-checks.jobs[1].genesis-allocs-all-ok.requires = $prependedTargets" -i .circleci/continue_config.yml diff --git a/validation/promotion_test.go b/validation/promotion_test.go index a11d359ed..28daebc70 100644 --- a/validation/promotion_test.go +++ b/validation/promotion_test.go @@ -4,6 +4,7 @@ import ( "testing" . "github.com/ethereum-optimism/superchain-registry/superchain" + "github.com/ethereum-optimism/superchain-registry/validation/common" ) // WARNING: this test must not run along side any other tests, because it mutates global objects. @@ -11,7 +12,7 @@ import ( func TestPromotion(t *testing.T) { for _, chain := range OPChains { chain := chain - t.Run(perChainTestName(chain), func(t *testing.T) { + t.Run(common.PerChainTestName(chain), func(t *testing.T) { t.Parallel() if chain.StandardChainCandidate { // do not allow any test exclusions diff --git a/validation/utils_test.go b/validation/utils_test.go index 33765c866..8ad38b7aa 100644 --- a/validation/utils_test.go +++ b/validation/utils_test.go @@ -5,16 +5,10 @@ import ( "math/big" "testing" - "github.com/ethereum-optimism/superchain-registry/superchain" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" ) -// perChainTestName ensures test can easily be filtered by chain name or chain id using the -run=regex testflag. -func perChainTestName(chain *superchain.ChainConfig) string { - return chain.Name + fmt.Sprintf(" (%d)", chain.ChainID) -} - // isBigIntWithinBounds returns true if actual is within bounds, where the bounds are [lower bound, upper bound] and are inclusive. var isBigIntWithinBounds = func(actual *big.Int, bounds [2]*big.Int) bool { if (bounds[1].Cmp(bounds[0])) < 0 { diff --git a/validation/validation_test.go b/validation/validation_test.go index e065df9c0..266094bd5 100644 --- a/validation/validation_test.go +++ b/validation/validation_test.go @@ -4,6 +4,7 @@ import ( "testing" . "github.com/ethereum-optimism/superchain-registry/superchain" + "github.com/ethereum-optimism/superchain-registry/validation/common" ) // Test names @@ -26,6 +27,7 @@ const ( StandardContractVersionsTest = "Standard_Contract_Versions" OptimismPortal2ParamsTest = "Optimism_Portal_2_Params" KeyHandoverTest = "Key_Handover" + GenesisAllocsMetadataTest = "Genesis_Allocs_Metadata" ) func TestValidation(t *testing.T) { @@ -33,7 +35,7 @@ func TestValidation(t *testing.T) { // on each OP chain. for _, chain := range OPChains { chain := chain - t.Run(perChainTestName(chain), func(t *testing.T) { + t.Run(common.PerChainTestName(chain), func(t *testing.T) { t.Parallel() testValidation(t, chain) }) @@ -81,6 +83,7 @@ func testStandardCandidate(t *testing.T, chain *ChainConfig) { t.Run(L2SecurityConfigTest, func(t *testing.T) { testL2SecurityConfig(t, chain) }) // Other t.Run(DataAvailabilityTypeTest, func(t *testing.T) { testDataAvailabilityType(t, chain) }) + t.Run(GenesisAllocsMetadataTest, func(t *testing.T) { testGenesisAllocsMetadata(t, chain) }) } // testStandard should be applied only to a fully Standard Chain, From 23d6ccb31be9f554f1acb5182e1c4f95c03db872 Mon Sep 17 00:00:00 2001 From: Sam Stokes <35908605+bitwiseguy@users.noreply.github.com> Date: Tue, 3 Sep 2024 16:23:00 -0400 Subject: [PATCH 19/30] circleci: use context to pass rpc urls (#544) * circleci: use context to pass rpc urls * circleci: add rpc context to hourly/nightly jobs --- .circleci/continue_config.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.circleci/continue_config.yml b/.circleci/continue_config.yml index 21112a654..ebd8d8ab7 100644 --- a/.circleci/continue_config.yml +++ b/.circleci/continue_config.yml @@ -242,6 +242,7 @@ workflows: - golang-validate-all: context: - slack + - oplabs-rpc-urls - golang-test: context: - slack @@ -257,6 +258,7 @@ workflows: - golang-promotion-test: context: - slack + - oplabs-rpc-urls triggers: - schedule: cron: "0 0 * * *" @@ -270,10 +272,16 @@ workflows: matrix: parameters: chainid: [] # This list will be replaced by the generate_test_config.sh script + context: + - oplabs-rpc-urls - genesis-allocs-all-ok: requires: [] # This list will be replaced by the generate_test_config.sh script + context: + - oplabs-rpc-urls - golang-lint - golang-modules-tidy - golang-test - - golang-validate-modified + - golang-validate-modified: + context: + - oplabs-rpc-urls - check-codegen From 29537da5a6f85a5e3ac1b63aa258a39f65f1b408 Mon Sep 17 00:00:00 2001 From: George Knee Date: Tue, 3 Sep 2024 21:26:17 +0100 Subject: [PATCH 20/30] Adds validation metadata for chain with id 9897 (arena-z / nod) (#540) * add arena z testnet * remove temporary files (fixmeup) * update genesis_creation_commit chose the one immediately before the l1StartingBlockTime * upgrade validation code to cope with forge command * just lint-all * make go_version inference work even when in a subdir with no go.mod file * run commands from the correct dirs * fix typo * git restore --source=main --staged --worktree superchain * just codegen * Update superchain/configs/mainnet/superchain.toml --------- Co-authored-by: Vinod Damle --- validation/genesis/commands.go | 16 +++- validation/genesis/genesis-allocs_test.go | 44 +++++++---- validation/genesis/monorepo-outputs.sh | 2 +- .../validation-inputs/9897/deploy-config.json | 76 +++++++++++++++++++ .../genesis/validation-inputs/9897/meta.toml | 4 + 5 files changed, 126 insertions(+), 16 deletions(-) create mode 100755 validation/genesis/validation-inputs/9897/deploy-config.json create mode 100755 validation/genesis/validation-inputs/9897/meta.toml diff --git a/validation/genesis/commands.go b/validation/genesis/commands.go index c6843dfe2..11508c75f 100644 --- a/validation/genesis/commands.go +++ b/validation/genesis/commands.go @@ -17,9 +17,10 @@ type GeneratorFn func(uint64, string) string var GenesisCreationCommand = map[string]GeneratorFn{ "opnode1": opnode1, "opnode2": opnode2, + "forge1": forge1, } -func opnode1(chainId uint64, l1rpcURL string) string { +func opnode1(chainId uint64, l1rpcURL string) string { // runs from monorepo root return strings.Join([]string{ "go run op-node/cmd/main.go genesis l2", fmt.Sprintf("--deploy-config=./packages/contracts-bedrock/deploy-config/%d.json", chainId), @@ -31,7 +32,7 @@ func opnode1(chainId uint64, l1rpcURL string) string { " ") } -func opnode2(chainId uint64, l1rpcURL string) string { +func opnode2(chainId uint64, l1rpcURL string) string { // runs from monorepo root return strings.Join([]string{ "go run op-node/cmd/main.go genesis l2", fmt.Sprintf(" --deploy-config=./packages/contracts-bedrock/deploy-config/%d.json", chainId), @@ -43,6 +44,17 @@ func opnode2(chainId uint64, l1rpcURL string) string { " ") } +func forge1(chainId uint64, l1rpcURL string) string { // runs from packages/contracts-bedrock directory + return strings.Join([]string{ + fmt.Sprintf("CONTRACT_ADDRESSES_PATH=./deployments/%d/.deploy", chainId), + fmt.Sprintf("DEPLOY_CONFIG_PATH=./deploy-config/%d.json", chainId), + "STATE_DUMP_PATH=statedump.json", + "forge script ./scripts/L2Genesis.s.sol:L2Genesis", + "--sig 'runWithStateDump()'", + }, + " ") +} + var BuildCommand = map[string]string{ "pnpm": "pnpm install --no-frozen-lockfile", "yarn": "yarn install --no-frozen-lockfile", diff --git a/validation/genesis/genesis-allocs_test.go b/validation/genesis/genesis-allocs_test.go index 9b84bbf0c..3f9284e25 100644 --- a/validation/genesis/genesis-allocs_test.go +++ b/validation/genesis/genesis-allocs_test.go @@ -9,12 +9,14 @@ import ( "path/filepath" "runtime" "strconv" + "strings" "testing" . "github.com/ethereum-optimism/superchain-registry/superchain" . "github.com/ethereum-optimism/superchain-registry/validation/common" "github.com/ethereum/go-ethereum/core" + "github.com/ethereum/go-ethereum/core/types" "github.com/stretchr/testify/require" ) @@ -36,7 +38,7 @@ func TestMain(m *testing.M) { needToClone := os.IsNotExist(err) if needToClone { mustExecuteCommandInDir(thisDir, - exec.Command("git", "clone", "https://github.com/ethereum-optimism/optimism.git", temporaryOptimismDir)) + exec.Command("git", "clone", "--recurse-submodules", "https://github.com/ethereum-optimism/optimism.git", temporaryOptimismDir)) } // Run tests @@ -116,7 +118,14 @@ func testGenesisAllocs(t *testing.T, chain *ChainConfig) { log.Fatalf("Failed to write deployments: %v", err) } - mustExecuteCommandInDir(thisDir, exec.Command("cp", "./monorepo-outputs.sh", monorepoDir)) + var runDir string + if strings.HasPrefix(vis.GenesisCreationCommand, "forge") { + runDir = contractsDir + } else { + runDir = monorepoDir + } + + mustExecuteCommandInDir(thisDir, exec.Command("cp", "./monorepo-outputs.sh", runDir)) buildCommand := BuildCommand[vis.MonorepoBuildCommand] if vis.NodeVersion == "" { panic("must set node_version in meta.toml") @@ -137,19 +146,28 @@ func testGenesisAllocs(t *testing.T, chain *ChainConfig) { go streamOutputToLogger(stderrPipe, t) t.Log("🛠️ Regenerating genesis...") - mustExecuteCommandInDir(monorepoDir, cmd) + mustExecuteCommandInDir(runDir, cmd) t.Log("🛠️ Comparing registry genesis.alloc with regenerated genesis.alloc...") - expectedData, err := os.ReadFile(path.Join(monorepoDir, "expected-genesis.json")) - require.NoError(t, err) - - gen := core.Genesis{} - - err = json.Unmarshal(expectedData, &gen) - require.NoError(t, err) - - expectedData, err = json.MarshalIndent(gen.Alloc, "", " ") - require.NoError(t, err) + var expectedData []byte + + if strings.HasPrefix(vis.GenesisCreationCommand, "forge") { + expectedData, err = os.ReadFile(path.Join(contractsDir, "statedump.json")) + require.NoError(t, err) + allocs := types.GenesisAlloc{} + err = json.Unmarshal(expectedData, &allocs) + require.NoError(t, err) + expectedData, err = json.MarshalIndent(allocs, "", " ") + require.NoError(t, err) + } else { + expectedData, err = os.ReadFile(path.Join(monorepoDir, "expected-genesis.json")) + require.NoError(t, err) + gen := core.Genesis{} + err = json.Unmarshal(expectedData, &gen) + require.NoError(t, err) + expectedData, err = json.MarshalIndent(gen.Alloc, "", " ") + require.NoError(t, err) + } g, err := core.LoadOPStackGenesis(chainId) require.NoError(t, err) diff --git a/validation/genesis/monorepo-outputs.sh b/validation/genesis/monorepo-outputs.sh index b589bf18f..556cb80b9 100755 --- a/validation/genesis/monorepo-outputs.sh +++ b/validation/genesis/monorepo-outputs.sh @@ -9,7 +9,7 @@ echo "Running install command" eval $2 echo "Installing and selecting correct go version" -go_version=$(grep -m 1 '^go ' go.mod | awk '{print $2}') +go_version=$(go mod edit -print | grep -m 1 '^go ' | awk '{print $2}') # Source the gvm script to load gvm functions into the shell # NOTE gvm is necessary because older versions of op-node used a diff --git a/validation/genesis/validation-inputs/9897/deploy-config.json b/validation/genesis/validation-inputs/9897/deploy-config.json new file mode 100755 index 000000000..e1e2cb776 --- /dev/null +++ b/validation/genesis/validation-inputs/9897/deploy-config.json @@ -0,0 +1,76 @@ +{ + "l1ChainID": 11155111, + "l2ChainID": 9897, + "l2BlockTime": 2, + "maxSequencerDrift": 600, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0xBBC751e8A6285F22C8B6305D1158071f204Dbca4", + "batchInboxAddress": "0xff00000000000000000000000000000000009897", + "batchSenderAddress": "0xaBecfbb176FA579ee7E1Ed1947E375B118433be0", + "l1StartingBlockTag": "0x0c9c133c27d12e35a7b3ff2358f2dc1ff5eda8cced373dccb6cf394302bfd135", + "l2OutputOracleSubmissionInterval": 1800, + "l2OutputOracleStartingTimestamp": 1722432480, + "l2OutputOracleStartingBlockNumber": 0, + "l2OutputOracleProposer": "0xBF80C17ee655837E25208436ed543217899B4bd8", + "l2OutputOracleChallenger": "0x776beE5229Eb00349D6Fc956EFAD7985ee36804d", + "l2GenesisBlockGasLimit": "0x1c9c380", + "l1BlockTime": 12, + "baseFeeVaultRecipient": "0x776beE5229Eb00349D6Fc956EFAD7985ee36804d", + "l1FeeVaultRecipient": "0x776beE5229Eb00349D6Fc956EFAD7985ee36804d", + "sequencerFeeVaultRecipient": "0x776beE5229Eb00349D6Fc956EFAD7985ee36804d", + "baseFeeVaultMinimumWithdrawalAmount": "0xde0b6b3a7640000", + "l1FeeVaultMinimumWithdrawalAmount": "0xde0b6b3a7640000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0xde0b6b3a7640000", + "baseFeeVaultWithdrawalNetwork": 1, + "l1FeeVaultWithdrawalNetwork": 1, + "sequencerFeeVaultWithdrawalNetwork": 1, + "proxyAdminOwner": "0x776beE5229Eb00349D6Fc956EFAD7985ee36804d", + "finalSystemOwner": "0x776beE5229Eb00349D6Fc956EFAD7985ee36804d", + "superchainConfigGuardian": "0x776beE5229Eb00349D6Fc956EFAD7985ee36804d", + "finalizationPeriodSeconds": 12, + "fundDevAccounts": false, + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "gasPriceOracleOverhead": 188, + "gasPriceOracleScalar": 1000000, + "gasPriceOracleBaseFeeScalar": 1368, + "gasPriceOracleBlobBaseFeeScalar": 810949, + "enableGovernance": false, + "governanceTokenSymbol": "GT", + "governanceTokenName": "Governance Token", + "governanceTokenOwner": "0x776beE5229Eb00349D6Fc956EFAD7985ee36804d", + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250, + "eip1559Elasticity": 10, + "l2GenesisRegolithTimeOffset": "0x0", + "l2GenesisDeltaTimeOffset": "0x0", + "l2GenesisCanyonTimeOffset": "0x0", + "l2GenesisEcotoneTimeOffset": "0x0", + "l2GenesisFjordTimeOffset": "0x0", + "systemConfigStartBlock": 0, + "requiredProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", + "recommendedProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", + "faultGameAbsolutePrestate": "0x03ef540fa15fd44ab27a760adf1284c7b0c2a3b95d5c67aae599e1ff06fd3e54", + "faultGameMaxDepth": 73, + "faultGameClockExtension": 10800, + "faultGameMaxClockDuration": 302400, + "faultGameGenesisBlock": 0, + "faultGameGenesisOutputRoot": "0x0000000000000000000000000000000000000000000000000000000000000000", + "faultGameSplitDepth": 32, + "faultGameWithdrawalDelay": 604800, + "preimageOracleMinProposalSize": 1800000, + "preimageOracleChallengePeriod": 86400, + "proofMaturityDelaySeconds": 604800, + "disputeGameFinalityDelaySeconds": 302400, + "respectedGameType": 0, + "useFaultProofs": false, + "l1CancunTimeOffset": "0x0", + "useCustomGasToken": false, + "customGasTokenAddress": "0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE", + "usePlasma": false, + "daCommitmentType": "GenericCommitment", + "daChallengeWindow": 160, + "daResolveWindow": 160, + "daBondSize": 1000000, + "daResolverRefundPercentage": 100 +} diff --git a/validation/genesis/validation-inputs/9897/meta.toml b/validation/genesis/validation-inputs/9897/meta.toml new file mode 100755 index 000000000..7ea4ecbfc --- /dev/null +++ b/validation/genesis/validation-inputs/9897/meta.toml @@ -0,0 +1,4 @@ +genesis_creation_commit = "c2f290d479f7319776205c2640f140a8423cb987" +node_version = "18.12.1" +monorepo_build_command = "pnpm" +genesis_creation_command = "forge1" From b8d06d9561d6c2f3f8b47d2acfd6283f8e5b8b2e Mon Sep 17 00:00:00 2001 From: George Knee Date: Tue, 3 Sep 2024 21:51:40 +0100 Subject: [PATCH 21/30] Modify validation data for Lisk (#543) * modify deploy-config validation input metadata for lisk mainnet * run git submodule update during test * trigger genesis validation recheck when deploy-config file changes --- validation/genesis/genesis-allocs_test.go | 5 +++-- validation/genesis/monorepo-outputs.sh | 8 ++++---- .../validation-inputs/1135/deploy-config.json | 20 +++++++++---------- .../validation-inputs/generate-test-config.sh | 4 ++-- 4 files changed, 19 insertions(+), 18 deletions(-) diff --git a/validation/genesis/genesis-allocs_test.go b/validation/genesis/genesis-allocs_test.go index 3f9284e25..add3ad822 100644 --- a/validation/genesis/genesis-allocs_test.go +++ b/validation/genesis/genesis-allocs_test.go @@ -93,6 +93,7 @@ func testGenesisAllocs(t *testing.T, chain *ChainConfig) { // blow away any leftover files from the previous run t.Logf("🛠️ Resetting monorepo to %s...", monorepoCommit) mustExecuteCommandInDir(monorepoDir, exec.Command("git", "reset", "--hard", monorepoCommit)) + mustExecuteCommandInDir(monorepoDir, exec.Command("git", "submodule", "update")) t.Log("🛠️ Deleting node_modules...") mustExecuteCommandInDir(monorepoDir, exec.Command("rm", "-rf", "node_modules")) @@ -175,9 +176,9 @@ func testGenesisAllocs(t *testing.T, chain *ChainConfig) { gotData, err := json.MarshalIndent(g.Alloc, "", " ") require.NoError(t, err) - err = os.WriteFile(path.Join(monorepoDir, "want-alloc.json"), expectedData, os.ModePerm) + err = os.WriteFile(path.Join(monorepoDir, "want-alloc.json"), expectedData, os.ModePerm) // regenerated require.NoError(t, err) - err = os.WriteFile(path.Join(monorepoDir, "got-alloc.json"), gotData, os.ModePerm) + err = os.WriteFile(path.Join(monorepoDir, "got-alloc.json"), gotData, os.ModePerm) // read from registry require.NoError(t, err) require.Equal(t, string(expectedData), string(gotData)) diff --git a/validation/genesis/monorepo-outputs.sh b/validation/genesis/monorepo-outputs.sh index 556cb80b9..2ed717253 100755 --- a/validation/genesis/monorepo-outputs.sh +++ b/validation/genesis/monorepo-outputs.sh @@ -1,14 +1,14 @@ export NVM_DIR="$HOME/.nvm" [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm -echo "Installing and selecting correct Node version" +echo "Installing and selecting correct Node version..." nvm install $1 nvm use $1 -echo "Running install command" +echo "Running install command..." eval $2 -echo "Installing and selecting correct go version" +echo "Installing and selecting correct go version..." go_version=$(go mod edit -print | grep -m 1 '^go ' | awk '{print $2}') # Source the gvm script to load gvm functions into the shell @@ -20,5 +20,5 @@ go_version=$(go mod edit -print | grep -m 1 '^go ' | awk '{print $2}') gvm install go${go_version} gvm use go${go_version} -echo "Running op-node genesis l2 command" +echo "Running l2 genesis creation command..." eval "$3" diff --git a/validation/genesis/validation-inputs/1135/deploy-config.json b/validation/genesis/validation-inputs/1135/deploy-config.json index 0324bd344..2d3bc49b1 100644 --- a/validation/genesis/validation-inputs/1135/deploy-config.json +++ b/validation/genesis/validation-inputs/1135/deploy-config.json @@ -16,16 +16,16 @@ "l2OutputOracleChallenger": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", "l2GenesisBlockGasLimit": "0x1c9c380", "l1BlockTime": 12, - "baseFeeVaultRecipient": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", - "l1FeeVaultRecipient": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", - "sequencerFeeVaultRecipient": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", - "baseFeeVaultMinimumWithdrawalAmount": "0x1bc16d674ec80000", - "l1FeeVaultMinimumWithdrawalAmount": "0x1bc16d674ec80000", - "sequencerFeeVaultMinimumWithdrawalAmount": "0x1bc16d674ec80000", - "baseFeeVaultWithdrawalNetwork": 1, - "l1FeeVaultWithdrawalNetwork": 1, - "sequencerFeeVaultWithdrawalNetwork": 1, - "proxyAdminOwner": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", + "baseFeeVaultRecipient": "0xdA6e5640aFB2ED212Ba3a6fd83076e2ad3daD185", + "l1FeeVaultRecipient": "0xdA6e5640aFB2ED212Ba3a6fd83076e2ad3daD185", + "sequencerFeeVaultRecipient": "0xdA6e5640aFB2ED212Ba3a6fd83076e2ad3daD185", + "baseFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "l1FeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "baseFeeVaultWithdrawalNetwork": 0, + "l1FeeVaultWithdrawalNetwork": 0, + "sequencerFeeVaultWithdrawalNetwork": 0, + "proxyAdminOwner": "0xdA6e5640aFB2ED212Ba3a6fd83076e2ad3daD185", "finalSystemOwner": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", "superchainConfigGuardian": "0xBeA2Bc852a160B8547273660E22F4F08C2fa9Bbb", "finalizationPeriodSeconds": 604800, diff --git a/validation/genesis/validation-inputs/generate-test-config.sh b/validation/genesis/validation-inputs/generate-test-config.sh index 0ae4dbfc3..cae95215b 100644 --- a/validation/genesis/validation-inputs/generate-test-config.sh +++ b/validation/genesis/validation-inputs/generate-test-config.sh @@ -3,7 +3,7 @@ set -o errexit -o pipefail set -x # Get the list of changed files -targetList=$(git diff --name-only --merge-base main -- validation/genesis/*.toml) +targetList=$(git diff --name-only --merge-base main -- "validation/genesis/*.toml" "validation/genesis/*.json") # Check if targetList is empty if [ -z "$targetList" ]; then @@ -12,7 +12,7 @@ if [ -z "$targetList" ]; then fi # Process the targetList to extract directory names and then the base names -targetList=$(echo "$targetList" | xargs dirname | xargs basename) +targetList=$(echo "$targetList" | xargs dirname | xargs basename | sort -u) # Join the array elements with commas and wrap each element in quotes targets=$(echo "$targetList" | sed 's/.*/"&"/' | tr '\n' ',') From acc3dbe1d2c02b3a750ddca95e8d377c8f32c97f Mon Sep 17 00:00:00 2001 From: refcell Date: Wed, 4 Sep 2024 08:33:24 -0400 Subject: [PATCH 22/30] feat: Json Configs (#545) --- superchain/configs/configs.json | 1159 +++++++++++++++++++++++++++ superchain/configs/configs.toml | 1088 ------------------------- superchain/internal/codegen/main.go | 27 +- 3 files changed, 1169 insertions(+), 1105 deletions(-) create mode 100644 superchain/configs/configs.json delete mode 100644 superchain/configs/configs.toml diff --git a/superchain/configs/configs.json b/superchain/configs/configs.json new file mode 100644 index 000000000..8ba5812f1 --- /dev/null +++ b/superchain/configs/configs.json @@ -0,0 +1,1159 @@ +{ + "superchains": [ + { + "name": "mainnet", + "config": { + "Name": "Mainnet", + "L1": { + "ChainID": 1, + "PublicRPC": "https://ethereum-rpc.publicnode.com", + "Explorer": "https://etherscan.io" + }, + "ProtocolVersionsAddr": "0x8062AbC286f5e7D9428a0Ccb9AbD71e50d93b935", + "SuperchainConfigAddr": "0x95703e0982140D16f8ebA6d158FccEde42f04a4C" + }, + "chains": [ + { + "Name": "OP Mainnet", + "l2_chain_id": 10, + "PublicRPC": "https://mainnet.optimism.io", + "SequencerRPC": "https://mainnet-sequencer.optimism.io", + "Explorer": "https://explorer.optimism.io", + "SuperchainLevel": 1, + "StandardChainCandidate": false, + "SuperchainTime": 0, + "batch_inbox_address": "0xFF00000000000000000000000000000000000010", + "Superchain": "mainnet", + "Chain": "op", + "canyon_time": 1704992401, + "delta_time": 1708560000, + "ecotone_time": 1710374401, + "fjord_time": 1720627201, + "granite_time": 1726070401, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0x438335a20d98863a4c0c97999eb2481921ccd28553eac6f913af7c12aec04108", + "Number": 17422590 + }, + "L2": { + "Hash": "0xdbf6a80fef073de06add9b0d14026d6e5a86c85f6d102c36d3d8e9cf89c2afd3", + "Number": 105235063 + }, + "l2_time": 1686068903, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x6887246668a3b87F54DeB3b94Ba47a6f63F32985", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0xdE1FCfB0851916CA5101820A69b13a4E276bd81F", + "AnchorStateRegistryProxy": "0x18DAc71c228D1C32c99489B7323d441E1175e443", + "BatchSubmitter": "0x6887246668a3b87F54DeB3b94Ba47a6f63F32985", + "Challenger": "0x9BA6e03D8B90dE867373Db8cF1A58d2F7F006b3A", + "DelayedWETHProxy": "0xE497B094d6DbB3D5E4CaAc9a14696D7572588d14", + "DisputeGameFactoryProxy": "0xe5965Ab5962eDc7477C8520243A95517CD252fA9", + "FaultDisputeGame": "0x4146DF64D83acB0DcB0c1a4884a16f090165e122", + "Guardian": "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2", + "L1CrossDomainMessengerProxy": "0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1", + "L1ERC721BridgeProxy": "0x5a7749f83b81B301cAb5f48EB8516B986DAef23D", + "L1StandardBridgeProxy": "0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1", + "MIPS": "0x0f8EdFbDdD3c0256A80AD8C0F2560B1807873C9c", + "OptimismMintableERC20FactoryProxy": "0x75505a97BD334E7BD3C476893285569C4136Fa0F", + "OptimismPortalProxy": "0xbEb5Fc579115071764c7423A4f12eDde41f106Ed", + "PermissionedDisputeGame": "0xE9daD167EF4DE8812C1abD013Ac9570C616599A0", + "PreimageOracle": "0xD326E10B8186e90F4E2adc5c13a2d0C137ee8b34", + "Proposer": "0x473300df21D047806A082244b417f96b32f13A33", + "ProxyAdmin": "0x543bA4AADBAb8f9025686Bd03993043599c6fB04", + "ProxyAdminOwner": "0x5a0Aae59D09fccBdDb6C6CcEB07B7279367C3d2A", + "SystemConfigOwner": "0x847B5c174615B1B7fDF770882256e2D3E95b9D92", + "SystemConfigProxy": "0x229047fed2591dbec1eF1118d64F7aF3dB9EB290", + "UnsafeBlockSigner": "0xAAAA45d9549EDA09E70937013520214382Ffc4A2" + } + }, + { + "Name": "Orderly Mainnet", + "l2_chain_id": 291, + "PublicRPC": "https://rpc.orderly.network", + "SequencerRPC": "https://rpc.orderly.network", + "Explorer": "https://explorer.orderly.network", + "SuperchainLevel": 0, + "StandardChainCandidate": false, + "SuperchainTime": 0, + "batch_inbox_address": "0x08aA34cC843CeEBcC88A627F18430294aA9780be", + "Superchain": "mainnet", + "Chain": "orderly", + "canyon_time": 1704992401, + "delta_time": 1708560000, + "ecotone_time": 1710374401, + "fjord_time": 1720627201, + "granite_time": 1726070401, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0x787d5dd296d63bc6e7a4158d4f109e1260740ee115f5ed5124b35dece1fa3968", + "Number": 18292529 + }, + "L2": { + "Hash": "0xe53c94ddd42714239429bd132ba2fa080c7e5cc7dca816ec6e482ec0418e6d7f", + "Number": 0 + }, + "l2_time": 1696608227, + "ExtraData": null, + "system_config": { + "batcherAddr": "0xf8dB8Aba597fF36cCD16fECfbb1B816B3236E9b8", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0x87630a802a3789463eC4b00f89b27b1e9f6b92e9", + "BatchSubmitter": "0xf8dB8Aba597fF36cCD16fECfbb1B816B3236E9b8", + "Challenger": "0xcE10372313Ca39Fbf75A09e7f4c0E57F070259f4", + "Guardian": "0xcE10372313Ca39Fbf75A09e7f4c0E57F070259f4", + "L1CrossDomainMessengerProxy": "0xc76543A64666d9a073FaEF4e75F651c88e7DBC08", + "L1ERC721BridgeProxy": "0x934Ab59Ef14b638653b1C0FEf7aB9a72186393DC", + "L1StandardBridgeProxy": "0xe07eA0436100918F157DF35D01dCE5c11b16D1F1", + "L2OutputOracleProxy": "0x5e76821C3c1AbB9fD6E310224804556C61D860e0", + "OptimismMintableERC20FactoryProxy": "0x7a69a90d8ea11E9618855da55D09E6F953730686", + "OptimismPortalProxy": "0x91493a61ab83b62943E6dCAa5475Dd330704Cc84", + "Proposer": "0x74BaD482a7f73C8286F50D8Aa03e53b7d24A5f3B", + "ProxyAdmin": "0xb570F4aD27e7De879A2E4F2F3DE27dBaBc20E9B9", + "ProxyAdminOwner": "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746", + "SystemConfigOwner": "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746", + "SystemConfigProxy": "0x886B187C3D293B1449A3A0F23Ca9e2269E0f2664", + "UnsafeBlockSigner": "0xceED24B1Fd4A4393f6A9D2B137D9597dd5482569" + } + }, + { + "Name": "Binary Mainnet", + "l2_chain_id": 624, + "PublicRPC": "https://rpc.zero.thebinaryholdings.com", + "SequencerRPC": "https://sequencer.bnry.mainnet.zeeve.net", + "Explorer": "https://explorer.thebinaryholdings.com/", + "SuperchainLevel": 0, + "StandardChainCandidate": false, + "SuperchainTime": null, + "batch_inbox_address": "0xFF00000000000000000000000000000000000624", + "Superchain": "mainnet", + "Chain": "tbn", + "canyon_time": 0, + "delta_time": 0, + "ecotone_time": 0, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": "0x04E9D7e336f79Cdab911b06133D3Ca2Cd0721ce3", + "genesis": { + "L1": { + "Hash": "0xdcc5838ee3dd0af995c87bec9614a09f08dd8979014876b42fd7e3ae044dd8c4", + "Number": 20175246 + }, + "L2": { + "Hash": "0xe222b4b07ee9c885d13ee341823c92aa449f9769ac68fb5f1e1d4e602a990a4a", + "Number": 0 + }, + "l2_time": 1719397463, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x7f9D9c1BCE1062E1077845eA39a0303429600a06", + "overhead": "0x0000000000000000000000000000000000000000000000000000000000000000", + "scalar": "0x010000000000000000000000000000000000000000000000000c5fc500000558", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0x8173904703995c6BbA59a42B8bBf8405F978758a", + "AnchorStateRegistryProxy": "0x275Abd1eB1FBaAB40Dcef5f3A588e2dF65801edc", + "BatchSubmitter": "0x7f9D9c1BCE1062E1077845eA39a0303429600a06", + "Challenger": "0x79DdF0745D14783cDC2a05624c585Ddce07F4A02", + "DelayedWETHProxy": "0x161914F701d090824c1A8a0f4e5666938f12848d", + "DisputeGameFactoryProxy": "0x0D7e0590c58e4aC9B14B3eD6163CF55223931699", + "Guardian": "0x87aab081Ac9F8ce80fb048f23280DF019036BA1d", + "L1CrossDomainMessengerProxy": "0x807d21e416434ae92c8E5bcA4d506781aFbBa380", + "L1ERC721BridgeProxy": "0x1b396e4dC6ECB0be33CF01C5a34E1a3a7D03c378", + "L1StandardBridgeProxy": "0xD1B30378CBF968E5525e8835219A5726A1e71D10", + "L2OutputOracleProxy": "0x012f4baa6e0F5Ac4dFDF47BDdd9CF68a2B17821e", + "MIPS": "0x4e66D89DDF5A9d86836ABb1d05Ff8fDb5aD32c9A", + "OptimismMintableERC20FactoryProxy": "0xa641e14B685b5E652865e14A4fBc07e51371D124", + "OptimismPortalProxy": "0x5ff88fcF8e9947f45F4cAf8FFd5231B5DdF05e0A", + "PreimageOracle": "0xB9fF3A5835144b0d2F4267A21e0c74458907c870", + "Proposer": "0x2b6cD940ABE0CAF2fd89155b99522548c00EBaB1", + "ProxyAdmin": "0x38593Cce8FaB9887Ef9760f5F6aB3d6C595143cF", + "ProxyAdminOwner": "0x48EC051349dDc7E8baBafCBfe27696ECF2A8a8B3", + "SuperchainConfig": "0x34bb53D7C525114A27F0FE2aF91bdDAd186abb12", + "SystemConfigOwner": "0x25A6E7c6f3d0fE89A656Fcf065614B74E55099fF", + "SystemConfigProxy": "0x7aC7e5989EaC278B7BbfeF560871a2026baD472c", + "UnsafeBlockSigner": "0xDbad225D1C0DaBc27f6a9d250dBb136413C0DFb4" + } + }, + { + "Name": "Lyra Chain", + "l2_chain_id": 957, + "PublicRPC": "https://rpc.lyra.finance", + "SequencerRPC": "https://rpc.lyra.finance", + "Explorer": "https://explorer.lyra.finance", + "SuperchainLevel": 0, + "StandardChainCandidate": false, + "SuperchainTime": 0, + "batch_inbox_address": "0x5f7f7f6DB967F0ef10BdA0678964DBA185d16c50", + "Superchain": "mainnet", + "Chain": "lyra", + "canyon_time": 1704992401, + "delta_time": 1708560000, + "ecotone_time": 1710374401, + "fjord_time": 1720627201, + "granite_time": 1726070401, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0x00b06b23108483a0b6af8ff726b5ed3f508b7986f72c12679b10d72c05839716", + "Number": 18574841 + }, + "L2": { + "Hash": "0x047f535b3da7ad4f96d353b5a439740b7591413daee0e2f27dd3aabb24581af2", + "Number": 0 + }, + "l2_time": 1700021615, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x14e4E97bDc195d399Ad8E7FC14451C279FE04c8e", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0xC845F9C4004EB35a8bde8ad89C4760a9c0e65CAB", + "BatchSubmitter": "0x14e4E97bDc195d399Ad8E7FC14451C279FE04c8e", + "Challenger": "0x91F4be0C264FAFA1fEd75c4440910Cba2cAd98e8", + "Guardian": "0x91F4be0C264FAFA1fEd75c4440910Cba2cAd98e8", + "L1CrossDomainMessengerProxy": "0x5456f02c08e9A018E42C39b351328E5AA864174A", + "L1ERC721BridgeProxy": "0x6CC3268794c5d3E3d9d52adEfC748B59d536cb22", + "L1StandardBridgeProxy": "0x61E44dC0dae6888B5a301887732217d5725B0bFf", + "L2OutputOracleProxy": "0x1145E7848c8B64c6cab86Fd6D378733385c5C3Ba", + "OptimismMintableERC20FactoryProxy": "0x08Dea366F26C25a08C8D1C3568ad07d1e587136d", + "OptimismPortalProxy": "0x85eA9c11cf3D4786027F7FD08F4406b15777e5f8", + "Proposer": "0x03e820562ffd2e0390787caD706EaF1FF98C2608", + "ProxyAdmin": "0x35d5D43271548c984662d4879FBc8e041Bc1Ff93", + "ProxyAdminOwner": "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746", + "SystemConfigOwner": "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746", + "SystemConfigProxy": "0x0e4C4CDd01ceCB01070E9Fdfe7600871e4ae996e", + "UnsafeBlockSigner": "0xB71B58FfE538628557433dbBfA08d45ee5a69B44" + } + }, + { + "Name": "Metal L2", + "l2_chain_id": 1750, + "PublicRPC": "https://rpc.metall2.com", + "SequencerRPC": "https://rpc.metall2.com", + "Explorer": "https://explorer.metall2.com", + "SuperchainLevel": 0, + "StandardChainCandidate": true, + "SuperchainTime": 0, + "batch_inbox_address": "0xc83f7D9F2D4A76E81145849381ABA02602373723", + "Superchain": "mainnet", + "Chain": "metal", + "canyon_time": 0, + "delta_time": 0, + "ecotone_time": 0, + "fjord_time": 1720627201, + "granite_time": 1726070401, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0x2493565ce8472656b7c22377c8d4d8ef5d17f78392c799ca5f2429b01e2c159c", + "Number": 19527340 + }, + "L2": { + "Hash": "0xd31c12ffff2d563897ad9a041c0d26790d635911bdbbfa589347fa955f75281e", + "Number": 0 + }, + "l2_time": 1711563515, + "ExtraData": null, + "system_config": { + "batcherAddr": "0xC94C243f8fb37223F3EB2f7961F7072602A51B8B", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0xd4b1EC0DEc3C7F12abD3ec27B7514880ae1C3a37", + "BatchSubmitter": "0xC94C243f8fb37223F3EB2f7961F7072602A51B8B", + "Challenger": "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746", + "Guardian": "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2", + "L1CrossDomainMessengerProxy": "0x0a47A44f1B2bb753474f8c830322554A96C9934D", + "L1ERC721BridgeProxy": "0x50D700e97967F9115e3f999bDB263d69F6704680", + "L1StandardBridgeProxy": "0x6d0f65D59b55B0FEC5d2d15365154DcADC140BF3", + "L2OutputOracleProxy": "0x3B1F7aDa0Fcc26B13515af752Dd07fB1CAc11426", + "OptimismMintableERC20FactoryProxy": "0x1aaab4E20d2e4Bb992b5BCA2125e8bd3588c8730", + "OptimismPortalProxy": "0x3F37aBdE2C6b5B2ed6F8045787Df1ED1E3753956", + "Proposer": "0xC8187d40AD440328104A52BBed2D8Efc5ab1F1F6", + "ProxyAdmin": "0x37Ff0ae34dadA1A95A4251d10ef7Caa868c7AC99", + "ProxyAdminOwner": "0x5a0Aae59D09fccBdDb6C6CcEB07B7279367C3d2A", + "SystemConfigOwner": "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746", + "SystemConfigProxy": "0x7BD909970B0EEdcF078De6Aeff23ce571663b8aA", + "UnsafeBlockSigner": "0x4a65F5da5e80DEFfEA844eAa15CE130e80605dc5" + } + }, + { + "Name": "RACE Mainnet", + "l2_chain_id": 6805, + "PublicRPC": "https://racemainnet.io", + "SequencerRPC": "https://racemainnet.io", + "Explorer": "https://racescan.io/", + "SuperchainLevel": 0, + "StandardChainCandidate": false, + "SuperchainTime": null, + "batch_inbox_address": "0xFF00000000000000000000000000000000006805", + "Superchain": "mainnet", + "Chain": "race", + "canyon_time": 0, + "delta_time": 0, + "ecotone_time": 0, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0xb6fd41e6c3515172c36d3912046264475eaad84c2c56e99d74f4abd1a75b63c9", + "Number": 20260129 + }, + "L2": { + "Hash": "0xa864791943836c37b40ea688f3853f2198afb683a3e168d48bfa76c9896e3e65", + "Number": 0 + }, + "l2_time": 1720421591, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x8CDa8351236199AF7532baD53D683Ddd9B275d89", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0x3d2BdE87466Cae97011702D2C305fd40EEBbbF0a", + "BatchSubmitter": "0x8CDa8351236199AF7532baD53D683Ddd9B275d89", + "Challenger": "0x2E7B9465B25C081c07274A31DbD05C6146f67961", + "Guardian": "0x2E7B9465B25C081c07274A31DbD05C6146f67961", + "L1CrossDomainMessengerProxy": "0xf54B2BAEF894cfF5511A5722Acaac0409F2F2d89", + "L1ERC721BridgeProxy": "0x0f33D824d74180598311b3025095727BeA61f219", + "L1StandardBridgeProxy": "0x680969A6c58183987c8126ca4DE6b59C6540Cd2a", + "L2OutputOracleProxy": "0x8bF8442d49d52377d735a90F19657a29f29aA83c", + "OptimismMintableERC20FactoryProxy": "0x1d1c4C89AD5FF486c3C67E3DD84A22CF05420711", + "OptimismPortalProxy": "0x0485Ca8A73682B3D3f5ae98cdca1E5b512E728e9", + "Proposer": "0x88D58BFbCD70c25409b67117fC1CDfeFDA113a78", + "ProxyAdmin": "0x9B3C6D1d33F1fd82Ebb8dFbE38dA162B329De191", + "ProxyAdminOwner": "0x5A669B2193718F189b0576c0cdcedfEd6f40F9Ea", + "SuperchainConfig": "0xCB73B7348705a9F925643150Eb00350719380FF8", + "SystemConfigOwner": "0xBac1ad52745162c0aA3711fe88Df1Cc67034a3B9", + "SystemConfigProxy": "0xCf6A32dB8b3313b3d439CE6909511c2c3415fa32", + "UnsafeBlockSigner": "0x9b5639D472D6764b70F5046Ac0B13438718398E0" + } + }, + { + "Name": "Base", + "l2_chain_id": 8453, + "PublicRPC": "https://mainnet.base.org", + "SequencerRPC": "https://mainnet-sequencer.base.org", + "Explorer": "https://explorer.base.org", + "SuperchainLevel": 0, + "StandardChainCandidate": true, + "SuperchainTime": 0, + "batch_inbox_address": "0xFf00000000000000000000000000000000008453", + "Superchain": "mainnet", + "Chain": "base", + "canyon_time": 1704992401, + "delta_time": 1708560000, + "ecotone_time": 1710374401, + "fjord_time": 1720627201, + "granite_time": 1726070401, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0x5c13d307623a926cd31415036c8b7fa14572f9dac64528e857a470511fc30771", + "Number": 17481768 + }, + "L2": { + "Hash": "0xf712aa9241cc24369b143cf6dce85f0902a9731e70d66818a3a5845b296c73dd", + "Number": 0 + }, + "l2_time": 1686789347, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x5050F69a9786F081509234F1a7F4684b5E5b76C9", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0x8EfB6B5c4767B09Dc9AA6Af4eAA89F749522BaE2", + "BatchSubmitter": "0x5050F69a9786F081509234F1a7F4684b5E5b76C9", + "Challenger": "0x6F8C5bA3F59ea3E76300E3BEcDC231D656017824", + "Guardian": "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2", + "L1CrossDomainMessengerProxy": "0x866E82a600A1414e583f7F13623F1aC5d58b0Afa", + "L1ERC721BridgeProxy": "0x608d94945A64503E642E6370Ec598e519a2C1E53", + "L1StandardBridgeProxy": "0x3154Cf16ccdb4C6d922629664174b904d80F2C35", + "L2OutputOracleProxy": "0x56315b90c40730925ec5485cf004d835058518A0", + "OptimismMintableERC20FactoryProxy": "0x05cc379EBD9B30BbA19C6fA282AB29218EC61D84", + "OptimismPortalProxy": "0x49048044D57e1C92A77f79988d21Fa8fAF74E97e", + "Proposer": "0x642229f238fb9dE03374Be34B0eD8D9De80752c5", + "ProxyAdmin": "0x0475cBCAebd9CE8AfA5025828d5b98DFb67E059E", + "ProxyAdminOwner": "0x7bB41C3008B3f03FE483B28b8DB90e19Cf07595c", + "SystemConfigOwner": "0x14536667Cd30e52C0b458BaACcB9faDA7046E056", + "SystemConfigProxy": "0x73a79Fab69143498Ed3712e519A88a918e1f4072", + "UnsafeBlockSigner": "0xAf6E19BE0F9cE7f8afd49a1824851023A8249e8a" + } + }, + { + "Name": "Mode", + "l2_chain_id": 34443, + "PublicRPC": "https://mainnet.mode.network", + "SequencerRPC": "https://mainnet-sequencer.mode.network", + "Explorer": "https://explorer.mode.network", + "SuperchainLevel": 0, + "StandardChainCandidate": true, + "SuperchainTime": 0, + "batch_inbox_address": "0x24E59d9d3Bd73ccC28Dc54062AF7EF7bFF58Bd67", + "Superchain": "mainnet", + "Chain": "mode", + "canyon_time": 1704992401, + "delta_time": 1708560000, + "ecotone_time": 1710374401, + "fjord_time": 1720627201, + "granite_time": 1726070401, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0xf9b1b22a7ef9d13f063ea467bcb70fb6e9f29698ecb7366a2cdf5af2165cacee", + "Number": 18586927 + }, + "L2": { + "Hash": "0xb0f682e12fc555fd5ce8fce51a59a67d66a5b46be28611a168260a549dac8a9b", + "Number": 0 + }, + "l2_time": 1700167583, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x99199a22125034c808ff20f377d91187E8050F2E", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0x50eF494573f28Cad6B64C31b7a00Cdaa48306e15", + "BatchSubmitter": "0x99199a22125034c808ff20f377d91187E8050F2E", + "Challenger": "0x309Fe2536d01867018D120b40e4676723C53A14C", + "Guardian": "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2", + "L1CrossDomainMessengerProxy": "0x95bDCA6c8EdEB69C98Bd5bd17660BaCef1298A6f", + "L1ERC721BridgeProxy": "0x2901dA832a4D0297FF0691100A8E496626cc626D", + "L1StandardBridgeProxy": "0x735aDBbE72226BD52e818E7181953f42E3b0FF21", + "L2OutputOracleProxy": "0x4317ba146D4933D889518a3e5E11Fe7a53199b04", + "OptimismMintableERC20FactoryProxy": "0x69216395A62dFb243C05EF4F1C27AF8655096a95", + "OptimismPortalProxy": "0x8B34b14c7c7123459Cf3076b8Cb929BE097d0C07", + "Proposer": "0x674F64D64Ddc198db83cd9047dF54BF89cCD0ddB", + "ProxyAdmin": "0x470d87b1dae09a454A43D1fD772A561a03276aB7", + "ProxyAdminOwner": "0x5a0Aae59D09fccBdDb6C6CcEB07B7279367C3d2A", + "SystemConfigOwner": "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746", + "SystemConfigProxy": "0x5e6432F18Bc5d497B1Ab2288a025Fbf9D69E2221", + "UnsafeBlockSigner": "0xa7fA9CA4ac88686A542C0f830d7378eAB4A0278F" + } + }, + { + "Name": "Zora", + "l2_chain_id": 7777777, + "PublicRPC": "https://rpc.zora.energy", + "SequencerRPC": "https://rpc.zora.energy", + "Explorer": "https://explorer.zora.energy", + "SuperchainLevel": 0, + "StandardChainCandidate": true, + "SuperchainTime": 0, + "batch_inbox_address": "0x6F54Ca6F6EdE96662024Ffd61BFd18f3f4e34DFf", + "Superchain": "mainnet", + "Chain": "zora", + "canyon_time": 1704992401, + "delta_time": 1708560000, + "ecotone_time": 1710374401, + "fjord_time": 1720627201, + "granite_time": 1726070401, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0xbdbd2847f7aa5f7cd1bd4c9f904057f4ba0b498c7e380199c01d240e3a41a84f", + "Number": 17473923 + }, + "L2": { + "Hash": "0x47555a45a1af8d4728ca337a1e48375a83919b1ea16591e070a07388b7364e29", + "Number": 0 + }, + "l2_time": 1686693839, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x625726c858dBF78c0125436C943Bf4b4bE9d9033", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0xEF8115F2733fb2033a7c756402Fc1deaa56550Ef", + "BatchSubmitter": "0x625726c858dBF78c0125436C943Bf4b4bE9d9033", + "Challenger": "0xcA4571b1ecBeC86Ea2E660d242c1c29FcB55Dc72", + "Guardian": "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2", + "L1CrossDomainMessengerProxy": "0xdC40a14d9abd6F410226f1E6de71aE03441ca506", + "L1ERC721BridgeProxy": "0x83A4521A3573Ca87f3a971B169C5A0E1d34481c3", + "L1StandardBridgeProxy": "0x3e2Ea9B92B7E48A52296fD261dc26fd995284631", + "L2OutputOracleProxy": "0x9E6204F750cD866b299594e2aC9eA824E2e5f95c", + "OptimismMintableERC20FactoryProxy": "0xc52BC7344e24e39dF1bf026fe05C4e6E23CfBcFf", + "OptimismPortalProxy": "0x1a0ad011913A150f69f6A19DF447A0CfD9551054", + "Proposer": "0x48247032092e7b0ecf5dEF611ad89eaf3fC888Dd", + "ProxyAdmin": "0xD4ef175B9e72cAEe9f1fe7660a6Ec19009903b49", + "ProxyAdminOwner": "0x5a0Aae59D09fccBdDb6C6CcEB07B7279367C3d2A", + "SystemConfigOwner": "0xC72aE5c7cc9a332699305E29F68Be66c73b60542", + "SystemConfigProxy": "0xA3cAB0126d5F504B071b81a3e8A2BBBF17930d86", + "UnsafeBlockSigner": "0x3Dc8Dfd0709C835cAd15a6A27e089FF4cF4C9228" + } + } + ] + }, + { + "name": "sepolia", + "config": { + "Name": "Sepolia", + "L1": { + "ChainID": 11155111, + "PublicRPC": "https://ethereum-sepolia-rpc.publicnode.com", + "Explorer": "https://sepolia.etherscan.io" + }, + "ProtocolVersionsAddr": "0x79ADD5713B383DAa0a138d3C4780C7A1804a8090", + "SuperchainConfigAddr": "0xC2Be75506d5724086DEB7245bd260Cc9753911Be" + }, + "chains": [ + { + "Name": "Mode Testnet", + "l2_chain_id": 919, + "PublicRPC": "https://sepolia.mode.network", + "SequencerRPC": "https://sepolia.mode.network", + "Explorer": "https://sepolia.explorer.mode.network", + "SuperchainLevel": 0, + "StandardChainCandidate": true, + "SuperchainTime": 1703203200, + "batch_inbox_address": "0xcDDaE6148dA1E003C230E4527f9baEdc8a204e7E", + "Superchain": "sepolia", + "Chain": "mode", + "canyon_time": 1703203200, + "delta_time": 1703203200, + "ecotone_time": 1708534800, + "fjord_time": 1716998400, + "granite_time": 1723478400, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0x4370cafe528a1b8f2aaffc578094731daf69ff82fd9edc30d2d842d3763f3410", + "Number": 3778382 + }, + "L2": { + "Hash": "0x13c352562289a88ed33087a51b6b6c859a27709c8555c9def7cb9757c043acad", + "Number": 0 + }, + "l2_time": 1687867932, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x4e6BD53883107B063c502dDd49F9600Dc51b3DDc", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0x83D45725d6562d8CD717673D6bb4c67C07dC1905", + "BatchSubmitter": "0x4e6BD53883107B063c502dDd49F9600Dc51b3DDc", + "Challenger": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "Guardian": "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E", + "L1CrossDomainMessengerProxy": "0xc19a60d9E8C27B9A43527c3283B4dd8eDC8bE15C", + "L1ERC721BridgeProxy": "0x015a8c2e0a5fEd579dbb05fd290e413Adc6FC24A", + "L1StandardBridgeProxy": "0xbC5C679879B2965296756CD959C3C739769995E2", + "L2OutputOracleProxy": "0x2634BD65ba27AB63811c74A63118ACb312701Bfa", + "OptimismMintableERC20FactoryProxy": "0x00F7ab8c72D32f55cFf15e8901C2F9f2BF29A3C0", + "OptimismPortalProxy": "0x320e1580effF37E008F1C92700d1eBa47c1B23fD", + "Proposer": "0xe9e08A478e3a773c1B5D59014A0FDb901e6d1d69", + "ProxyAdmin": "0xE7413127F29E050Df65ac3FC9335F85bB10091AE", + "ProxyAdminOwner": "0x1Eb2fFc903729a0F03966B917003800b145F56E2", + "SystemConfigOwner": "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C", + "SystemConfigProxy": "0x15cd4f6e0CE3B4832B33cB9c6f6Fe6fc246754c2", + "UnsafeBlockSigner": "0x93A14E6894eEB4FF6a373E1Ad4f498c3a207afe4" + } + }, + { + "Name": "Metal L2 Testnet", + "l2_chain_id": 1740, + "PublicRPC": "https://testnet.rpc.metall2.com", + "SequencerRPC": "https://testnet.rpc.metall2.com", + "Explorer": "https://testnet.explorer.metall2.com", + "SuperchainLevel": 0, + "StandardChainCandidate": true, + "SuperchainTime": null, + "batch_inbox_address": "0x24567B64a86A4c966655fba6502a93dFb701E316", + "Superchain": "sepolia", + "Chain": "metal", + "canyon_time": 1708129622, + "delta_time": 1708385400, + "ecotone_time": 1708534800, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0x6a10927c70985f75898c48235b620acb2a48e9c777a40022f9dbad1b0c96a9c1", + "Number": 5304030 + }, + "L2": { + "Hash": "0xd24cf8e46b189b0c128dab4e46168520e3a4cdd390b239e8cc1e5abd22a629ae", + "Number": 0 + }, + "l2_time": 1708129620, + "ExtraData": null, + "system_config": { + "batcherAddr": "0xdb80Eca386AC72a55510e33CF9CF7533e75916eE", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0x394f844B9A0FC876935d1b0b791D9e94Ad905e8b", + "BatchSubmitter": "0xdb80Eca386AC72a55510e33CF9CF7533e75916eE", + "Challenger": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "Guardian": "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E", + "L1CrossDomainMessengerProxy": "0x5D335Aa7d93102110879e3B54985c5F08146091E", + "L1ERC721BridgeProxy": "0x5d6cE6917dBeeacF010c96BfFdaBE89e33a30309", + "L1StandardBridgeProxy": "0x21530aAdF4DCFb9c477171400E40d4ef615868BE", + "L2OutputOracleProxy": "0x75a6B961c8da942Ee03CA641B09C322549f6FA98", + "OptimismMintableERC20FactoryProxy": "0x49Ff2C4be882298e8CA7DeCD195c207c42B45F66", + "OptimismPortalProxy": "0x01D4dfC994878682811b2980653D03E589f093cB", + "ProxyAdmin": "0xF7Bc4b3a78C7Dd8bE9B69B3128EEB0D6776Ce18A", + "ProxyAdminOwner": "0x1Eb2fFc903729a0F03966B917003800b145F56E2", + "SystemConfigOwner": "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C", + "SystemConfigProxy": "0x5D63A8Dc2737cE771aa4a6510D063b6Ba2c4f6F2" + } + }, + { + "Name": "RACE Testnet", + "l2_chain_id": 6806, + "PublicRPC": "https://racetestnet.io", + "SequencerRPC": "https://racetestnet.io", + "Explorer": "https://testnet.racescan.io/", + "SuperchainLevel": 0, + "StandardChainCandidate": false, + "SuperchainTime": null, + "batch_inbox_address": "0xff00000000000000000000000000000000006806", + "Superchain": "sepolia", + "Chain": "race", + "canyon_time": 0, + "delta_time": 0, + "ecotone_time": 0, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0x28dd1dd74080560ef0b02f8f1ae31d1be75b01a70a5be6ef22e673cec538770f", + "Number": 6210400 + }, + "L2": { + "Hash": "0x994d67464c3368b8eb6f9770087399486b25d721a1868b95bb37de327b49ab89", + "Number": 0 + }, + "l2_time": 1719646560, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x584D61A30C7Ef1E8D547eE02099dADC487f49889", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0x1B573Db1000eA419B6dE8eB482C6d394179Bd1A3", + "BatchSubmitter": "0x584D61A30C7Ef1E8D547eE02099dADC487f49889", + "Challenger": "0xE6869aF6c871614df04902870Bb13d4505E1586c", + "Guardian": "0xE6869aF6c871614df04902870Bb13d4505E1586c", + "L1CrossDomainMessengerProxy": "0xdaeab17598938A4f27E50AC771249Ad7df12Ea7D", + "L1ERC721BridgeProxy": "0xBafb1a6e54e7750aF29489D65888d1c96Dfd66Df", + "L1StandardBridgeProxy": "0x289179e9d43A35D47239456251F9c2fdbf9fbeA2", + "L2OutputOracleProxy": "0xccac2B8FFc4f778242105F3a9E6B3Ae3F827fC6a", + "OptimismMintableERC20FactoryProxy": "0xbd023e7F08AE0274dCEd397D4B6630D697aC738A", + "OptimismPortalProxy": "0xF2891fc6819CDd6BD9221874619BB03A6277d72A", + "Proposer": "0x5a145E3F466FD6cC095214C700359df7894BaD21", + "ProxyAdmin": "0x4a0E8415e3eB85E7393445FD8E588283b62216C8", + "ProxyAdminOwner": "0xAc78E9B3Aa9373AE4bE2Ba5Bc9F716d7A746A65E", + "SuperchainConfig": "0x1696a64C7F170E46D32088E8eC29193300C35817", + "SystemConfigOwner": "0xE6869aF6c871614df04902870Bb13d4505E1586c", + "SystemConfigProxy": "0x07e7A3F25aA73dA15bc19B71FEF8f5511342a409", + "UnsafeBlockSigner": "0x89eA88ef4AC23f4C7Fdc611Fc9cD1c50DF702C2C" + } + }, + { + "Name": "Base Sepolia Testnet", + "l2_chain_id": 84532, + "PublicRPC": "https://sepolia.base.org", + "SequencerRPC": "https://sepolia-sequencer.base.org", + "Explorer": "https://sepolia-explorer.base.org", + "SuperchainLevel": 0, + "StandardChainCandidate": true, + "SuperchainTime": 0, + "batch_inbox_address": "0xfF00000000000000000000000000000000084532", + "Superchain": "sepolia", + "Chain": "base", + "canyon_time": 1699981200, + "delta_time": 1703203200, + "ecotone_time": 1708534800, + "fjord_time": 1716998400, + "granite_time": 1723478400, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 10, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0xcac9a83291d4dec146d6f7f69ab2304f23f5be87b1789119a0c5b1e4482444ed", + "Number": 4370868 + }, + "L2": { + "Hash": "0x0dcc9e089e30b90ddfc55be9a37dd15bc551aeee999d2e2b51414c54eaf934e4", + "Number": 0 + }, + "l2_time": 1695768288, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x6CDEbe940BC0F26850285cacA097C11c33103E47", + "overhead": "0x0000000000000000000000000000000000000000000000000000000000000834", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000f4240", + "gasLimit": 25000000 + } + }, + "Addresses": { + "AddressManager": "0x709c2B8ef4A9feFc629A8a2C1AF424Dc5BD6ad1B", + "AnchorStateRegistryProxy": "0x4C8BA32A5DAC2A720bb35CeDB51D6B067D104205", + "BatchSubmitter": "0xfc56E7272EEBBBA5bC6c544e159483C4a38f8bA3", + "Challenger": "0xDa3037Ff70Ac92CD867c683BD807e5A484857405", + "DelayedWETHProxy": "0x7698b262B7a534912c8366dD8a531672deEC634e", + "DisputeGameFactoryProxy": "0xd6E6dBf4F7EA0ac412fD8b65ED297e64BB7a06E1", + "FaultDisputeGame": "0x8A9bA50a785c3868bEf1FD4924b640A5e0ed54CF", + "Guardian": "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E", + "L1CrossDomainMessengerProxy": "0xC34855F4De64F1840e5686e64278da901e261f20", + "L1ERC721BridgeProxy": "0x21eFD066e581FA55Ef105170Cc04d74386a09190", + "L1StandardBridgeProxy": "0xfd0Bf71F60660E2f608ed56e1659C450eB113120", + "MIPS": "0xFF760A87E41144b336E29b6D4582427dEBdB6dee", + "OptimismMintableERC20FactoryProxy": "0xb1efB9650aD6d0CC1ed3Ac4a0B7f1D5732696D37", + "OptimismPortalProxy": "0x49f53e41452C74589E85cA1677426Ba426459e85", + "PermissionedDisputeGame": "0x3f5c770f17A6982d2B3Ac77F6fDC93BFE0330E17", + "PreimageOracle": "0x627F825CBd48c4102d36f287be71f4234426b9e4", + "Proposer": "0x20044a0d104E9e788A0C984A2B7eAe615afD046b", + "ProxyAdmin": "0x0389E59Aa0a41E4A413Ae70f0008e76CAA34b1F3", + "ProxyAdminOwner": "0x0fe884546476dDd290eC46318785046ef68a0BA9", + "SystemConfigOwner": "0x0fe884546476dDd290eC46318785046ef68a0BA9", + "SystemConfigProxy": "0xf272670eb55e895584501d564AfEB048bEd26194", + "UnsafeBlockSigner": "0xb830b99c95Ea32300039624Cb567d324D4b1D83C" + } + }, + { + "Name": "OP Sepolia Testnet", + "l2_chain_id": 11155420, + "PublicRPC": "https://sepolia.optimism.io", + "SequencerRPC": "https://sepolia-sequencer.optimism.io", + "Explorer": "https://sepolia-optimistic.etherscan.io", + "SuperchainLevel": 1, + "StandardChainCandidate": false, + "SuperchainTime": 0, + "batch_inbox_address": "0xff00000000000000000000000000000011155420", + "Superchain": "sepolia", + "Chain": "op", + "canyon_time": 1699981200, + "delta_time": 1703203200, + "ecotone_time": 1708534800, + "fjord_time": 1716998400, + "granite_time": 1723478400, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0x48f520cf4ddaf34c8336e6e490632ea3cf1e5e93b0b2bc6e917557e31845371b", + "Number": 4071408 + }, + "L2": { + "Hash": "0x102de6ffb001480cc9b8b548fd05c34cd4f46ae4aa91759393db90ea0409887d", + "Number": 0 + }, + "l2_time": 1691802540, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x8F23BB38F531600e5d8FDDaAEC41F13FaB46E98c", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0x9bFE9c5609311DF1c011c47642253B78a4f33F4B", + "AnchorStateRegistryProxy": "0x218CD9489199F321E1177b56385d333c5B598629", + "BatchSubmitter": "0x8F23BB38F531600e5d8FDDaAEC41F13FaB46E98c", + "Challenger": "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301", + "DelayedWETHProxy": "0xF3D833949133e4E4D3551343494b34079598EA5a", + "DisputeGameFactoryProxy": "0x05F9613aDB30026FFd634f38e5C4dFd30a197Fa1", + "FaultDisputeGame": "0xD5Bc8c45692aada756f2d68f0a2002d6Bf130C42", + "Guardian": "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E", + "L1CrossDomainMessengerProxy": "0x58Cc85b8D04EA49cC6DBd3CbFFd00B4B8D6cb3ef", + "L1ERC721BridgeProxy": "0xd83e03D576d23C9AEab8cC44Fa98d058D2176D1f", + "L1StandardBridgeProxy": "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1", + "MIPS": "0xFF760A87E41144b336E29b6D4582427dEBdB6dee", + "OptimismMintableERC20FactoryProxy": "0x868D59fF9710159C2B330Cc0fBDF57144dD7A13b", + "OptimismPortalProxy": "0x16Fc5058F25648194471939df75CF27A2fdC48BC", + "PermissionedDisputeGame": "0xBEA4384faCBcf51279962fbCFb8f16F9eD2fe0C6", + "PreimageOracle": "0x627F825CBd48c4102d36f287be71f4234426b9e4", + "Proposer": "0x49277EE36A024120Ee218127354c4a3591dc90A9", + "ProxyAdmin": "0x189aBAAaa82DfC015A588A7dbaD6F13b1D3485Bc", + "ProxyAdminOwner": "0x1Eb2fFc903729a0F03966B917003800b145F56E2", + "SystemConfigOwner": "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301", + "SystemConfigProxy": "0x034edD2A225f7f429A63E0f1D2084B9E0A93b538", + "UnsafeBlockSigner": "0x57CACBB0d30b01eb2462e5dC940c161aff3230D3" + } + }, + { + "Name": "Zora Sepolia Testnet", + "l2_chain_id": 999999999, + "PublicRPC": "https://sepolia.rpc.zora.energy", + "SequencerRPC": "https://sepolia.rpc.zora.energy", + "Explorer": "https://sepolia.explorer.zora.energy", + "SuperchainLevel": 0, + "StandardChainCandidate": true, + "SuperchainTime": 0, + "batch_inbox_address": "0xCd734290E4bd0200dAC631c7D4b9E8a33234e91f", + "Superchain": "sepolia", + "Chain": "zora", + "canyon_time": 1699981200, + "delta_time": 1703203200, + "ecotone_time": 1708534800, + "fjord_time": 1716998400, + "granite_time": 1723478400, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0xf782446a2487d900addb5d466a8597c7c543b59fa9aaa154d413830238f8798a", + "Number": 4548041 + }, + "L2": { + "Hash": "0x8b17d2d52564a5a90079d9c860e1386272579e87b17ea27a3868513f53facd74", + "Number": 0 + }, + "l2_time": 1698080004, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x3Cd868E221A3be64B161D596A7482257a99D857f", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0x27c9392144DFcB6dab113F737356C32435cD1D55", + "BatchSubmitter": "0x3Cd868E221A3be64B161D596A7482257a99D857f", + "Challenger": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "Guardian": "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E", + "L1CrossDomainMessengerProxy": "0x1bDBC0ae22bEc0c2f08B4dd836944b3E28fe9b7A", + "L1ERC721BridgeProxy": "0x16B0a4f451c4CB567703367e587E15Ac108e4311", + "L1StandardBridgeProxy": "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB", + "L2OutputOracleProxy": "0x2615B481Bd3E5A1C0C7Ca3Da1bdc663E8615Ade9", + "OptimismMintableERC20FactoryProxy": "0x5F3bdd57f01e88cE2F88f00685D30D6eb51A187c", + "OptimismPortalProxy": "0xeffE2C6cA9Ab797D418f0D91eA60807713f3536f", + "Proposer": "0xe8326a5839175dE7f467e66D8bB443aa70DA1c3e", + "ProxyAdmin": "0xE17071F4C216Eb189437fbDBCc16Bb79c4efD9c2", + "ProxyAdminOwner": "0x1Eb2fFc903729a0F03966B917003800b145F56E2", + "SystemConfigOwner": "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C", + "SystemConfigProxy": "0xB54c7BFC223058773CF9b739cC5bd4095184Fb08", + "UnsafeBlockSigner": "0x3609513933100689bd1f84782529A99239842344" + } + } + ] + }, + { + "name": "sepolia-dev-0", + "config": { + "Name": "Sepolia Dev 0", + "L1": { + "ChainID": 11155111, + "PublicRPC": "https://ethereum-sepolia-rpc.publicnode.com", + "Explorer": "https://sepolia.etherscan.io" + }, + "ProtocolVersionsAddr": "0x252CbE9517F731C618961D890D534183822dcC8d", + "SuperchainConfigAddr": "0x02d91Cf852423640d93920BE0CAdceC0E7A00FA7" + }, + "chains": [ + { + "Name": "OP Labs Sepolia devnet 0", + "l2_chain_id": 11155421, + "PublicRPC": "", + "SequencerRPC": "", + "Explorer": "", + "SuperchainLevel": 0, + "StandardChainCandidate": false, + "SuperchainTime": 0, + "batch_inbox_address": "0xFf00000000000000000000000000000011155421", + "Superchain": "sepolia-dev-0", + "Chain": "oplabs-devnet-0", + "canyon_time": 0, + "delta_time": 0, + "ecotone_time": 1706634000, + "fjord_time": 1715961600, + "granite_time": 1723046400, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0x5639be97000fec7131a880b19b664cae43f975c773f628a08a9bb658c2a68df0", + "Number": 5173577 + }, + "L2": { + "Hash": "0x027ae1f4f9a441f9c8a01828f3b6d05803a0f524c07e09263264a38b755f804b", + "Number": 0 + }, + "l2_time": 1706484048, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x19CC7073150D9f5888f09E0e9016d2a39667df14", + "overhead": "0x00000000000000000000000000000000000000000000000000000000000000bc", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000a6fe0", + "gasLimit": 30000000 + } + }, + "Addresses": { + "AddressManager": "0x3eb579b25F6b9547e0073c848389a768FD382296", + "AnchorStateRegistryProxy": "0x03b82AE60989863BCEb0BbD442A70568e5AefB85", + "BatchSubmitter": "0x19CC7073150D9f5888f09E0e9016d2a39667df14", + "Challenger": "0x8c20c40180751d93E939DDDee3517AE0d1EBeAd2", + "DelayedWETHProxy": "0xE99696a028171e31a72828A196C27c2Dd670E1aa", + "DisputeGameFactoryProxy": "0x2419423C72998eb1c6c15A235de2f112f8E38efF", + "FaultDisputeGame": "0x54416A2E28E8cbC761fbce0C7f107307991282e5", + "Guardian": "0x8c20c40180751d93E939DDDee3517AE0d1EBeAd2", + "L1CrossDomainMessengerProxy": "0x18e72C15FEE4e995454b919EfaA61D8f116F82dd", + "L1ERC721BridgeProxy": "0x1bb726658E039E8a9A4ac21A41fE5a0704760461", + "L1StandardBridgeProxy": "0x6D8bC564EF04AaF355a10c3eb9b00e349dd077ea", + "MIPS": "0xceDE5949A189aC60F41F1385a86DBce7Bd3B1943", + "OptimismMintableERC20FactoryProxy": "0xA16b8db3b5Cdbaf75158F34034B0537e528E17e2", + "OptimismPortalProxy": "0x76114bd29dFcC7a9892240D317E6c7C2A281Ffc6", + "PermissionedDisputeGame": "0x50573970b291726B881b204eD9F3c1D507e504cD", + "PreimageOracle": "0xB73342DdD69620e5Ab2Cc604Dad46434C2338025", + "Proposer": "0x95014c45078354Ff839f14192228108Eac82E00A", + "ProxyAdmin": "0x18d890A46A3556e7F36f28C79F6157BC7a59f867", + "ProxyAdminOwner": "0x4377BB0F0103992b31eC12b4d796a8687B8dC8E9", + "SystemConfigOwner": "0x8c20c40180751d93E939DDDee3517AE0d1EBeAd2", + "SystemConfigProxy": "0xa6b72407e2dc9EBF84b839B69A24C88929cf20F7", + "UnsafeBlockSigner": "0xa95B83e39AA78B00F12fe431865B563793D97AF5" + } + }, + { + "Name": "Base devnet 0", + "l2_chain_id": 11763072, + "PublicRPC": "", + "SequencerRPC": "", + "Explorer": "", + "SuperchainLevel": 0, + "StandardChainCandidate": false, + "SuperchainTime": 1706634000, + "batch_inbox_address": "0xfF00000000000000000000000000000011763072", + "Superchain": "sepolia-dev-0", + "Chain": "base-devnet-0", + "canyon_time": 1698436800, + "delta_time": 1706555000, + "ecotone_time": 1706634000, + "fjord_time": 1715961600, + "granite_time": 1723046400, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0x86252c512dc5bd7201d0532b31d50696ba84344a7cda545e04a98073a8e13d87", + "Number": 4344216 + }, + "L2": { + "Hash": "0x1ab91449a7c65b8cd6c06f13e2e7ea2d10b6f9cbf5def79f362f2e7e501d2928", + "Number": 0 + }, + "l2_time": 1695433056, + "ExtraData": null, + "system_config": { + "batcherAddr": "0x212dD524932bC43478688F91045F2682913ad8EE", + "overhead": "0x0000000000000000000000000000000000000000000000000000000000000834", + "scalar": "0x00000000000000000000000000000000000000000000000000000000000f4240", + "gasLimit": 25000000 + } + }, + "Addresses": { + "AddressManager": "0x882a60911d00867Fe4ea632C479cc48e583A8D69", + "BatchSubmitter": "0x7A43fD33e42054C965eE7175dd4590D2BDba79cB", + "Challenger": "0x5a533AaAC6cd81605b301a1077BC393A94658B6D", + "Guardian": "0x4F43c7422a9b2AC4BC6145Bd4eE206EA73cF8266", + "L1CrossDomainMessengerProxy": "0x2cbD403d5BA3949D24ee4dF57805eaC612C2662f", + "L1ERC721BridgeProxy": "0xc3016ED03E087d092d576B585F5222fFD9cadc10", + "L1StandardBridgeProxy": "0x5638e55db5Fcf7A58df525F1098E8569C8DbA80c", + "L2OutputOracleProxy": "0xB5901509329307E3f910f333Fa9C4B4A8EE7CE1A", + "OptimismMintableERC20FactoryProxy": "0xEAa11178375e6B1078d815d6F9F85cBbb69b09Cd", + "OptimismPortalProxy": "0x579c82A835B884336B632eeBeCC78FA08D3291Ec", + "Proposer": "0xf99C2Da4822Af652fe1BF55F99713980efe5D261", + "ProxyAdmin": "0xC5aE9023bFA79124ffA50169E1423E733D0166f1", + "ProxyAdminOwner": "0xAf6E0E871f38c7B653700F7CbAEDafaa2784D430", + "SystemConfigOwner": "0xAf6E0E871f38c7B653700F7CbAEDafaa2784D430", + "SystemConfigProxy": "0x7F67DC4959cb3E532B10A99F41bDD906C46FdFdE", + "UnsafeBlockSigner": "0xfd7bc3C58Fe4D4296F11F7843ebbA84D729A24B9" + } + } + ] + } + ] +} \ No newline at end of file diff --git a/superchain/configs/configs.toml b/superchain/configs/configs.toml deleted file mode 100644 index 6d9546d2a..000000000 --- a/superchain/configs/configs.toml +++ /dev/null @@ -1,1088 +0,0 @@ -############################################## -# DO NOT EDIT - THIS FILE IS AUTOGENERATED # -# DO NOT REMOVE - USED BY BINDINGS # -############################################## - -[[superchains]] - name = "mainnet" - [superchains.config] - name = "Mainnet" - protocol_versions_addr = "0x8062AbC286f5e7D9428a0Ccb9AbD71e50d93b935" - superchain_config_addr = "0x95703e0982140D16f8ebA6d158FccEde42f04a4C" - [superchains.config.l1] - chain_id = 1 - public_rpc = "https://ethereum-rpc.publicnode.com" - explorer = "https://etherscan.io" - - [[superchains.chains]] - name = "OP Mainnet" - chain_id = 10 - public_rpc = "https://mainnet.optimism.io" - sequencer_rpc = "https://mainnet-sequencer.optimism.io" - explorer = "https://explorer.optimism.io" - superchain_level = 1 - superchain_time = 0 - batch_inbox_addr = "0xFF00000000000000000000000000000000000010" - canyon_time = 1704992401 - delta_time = 1708560000 - ecotone_time = 1710374401 - fjord_time = 1720627201 - granite_time = 1726070401 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1686068903 - [superchains.chains.genesis.l1] - hash = "0x438335a20d98863a4c0c97999eb2481921ccd28553eac6f913af7c12aec04108" - number = 17422590 - [superchains.chains.genesis.l2] - hash = "0xdbf6a80fef073de06add9b0d14026d6e5a86c85f6d102c36d3d8e9cf89c2afd3" - number = 105235063 - [superchains.chains.genesis.system_config] - batcherAddress = "0x6887246668a3b87F54DeB3b94Ba47a6f63F32985" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0x847B5c174615B1B7fDF770882256e2D3E95b9D92" - ProxyAdminOwner = "0x5a0Aae59D09fccBdDb6C6CcEB07B7279367C3d2A" - Guardian = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" - Challenger = "0x9BA6e03D8B90dE867373Db8cF1A58d2F7F006b3A" - Proposer = "0x473300df21D047806A082244b417f96b32f13A33" - UnsafeBlockSigner = "0xAAAA45d9549EDA09E70937013520214382Ffc4A2" - BatchSubmitter = "0x6887246668a3b87F54DeB3b94Ba47a6f63F32985" - AddressManager = "0xdE1FCfB0851916CA5101820A69b13a4E276bd81F" - L1CrossDomainMessengerProxy = "0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1" - L1ERC721BridgeProxy = "0x5a7749f83b81B301cAb5f48EB8516B986DAef23D" - L1StandardBridgeProxy = "0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1" - L2OutputOracleProxy = "0x0000000000000000000000000000000000000000" - OptimismMintableERC20FactoryProxy = "0x75505a97BD334E7BD3C476893285569C4136Fa0F" - OptimismPortalProxy = "0xbEb5Fc579115071764c7423A4f12eDde41f106Ed" - SystemConfigProxy = "0x229047fed2591dbec1eF1118d64F7aF3dB9EB290" - ProxyAdmin = "0x543bA4AADBAb8f9025686Bd03993043599c6fB04" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x18DAc71c228D1C32c99489B7323d441E1175e443" - DelayedWETHProxy = "0xE497B094d6DbB3D5E4CaAc9a14696D7572588d14" - DisputeGameFactoryProxy = "0xe5965Ab5962eDc7477C8520243A95517CD252fA9" - FaultDisputeGame = "0x4146DF64D83acB0DcB0c1a4884a16f090165e122" - MIPS = "0x0f8EdFbDdD3c0256A80AD8C0F2560B1807873C9c" - PermissionedDisputeGame = "0xE9daD167EF4DE8812C1abD013Ac9570C616599A0" - PreimageOracle = "0xD326E10B8186e90F4E2adc5c13a2d0C137ee8b34" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "Orderly Mainnet" - chain_id = 291 - public_rpc = "https://rpc.orderly.network" - sequencer_rpc = "https://rpc.orderly.network" - explorer = "https://explorer.orderly.network" - superchain_level = 0 - superchain_time = 0 - batch_inbox_addr = "0x08aA34cC843CeEBcC88A627F18430294aA9780be" - canyon_time = 1704992401 - delta_time = 1708560000 - ecotone_time = 1710374401 - fjord_time = 1720627201 - granite_time = 1726070401 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1696608227 - [superchains.chains.genesis.l1] - hash = "0x787d5dd296d63bc6e7a4158d4f109e1260740ee115f5ed5124b35dece1fa3968" - number = 18292529 - [superchains.chains.genesis.l2] - hash = "0xe53c94ddd42714239429bd132ba2fa080c7e5cc7dca816ec6e482ec0418e6d7f" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0xf8dB8Aba597fF36cCD16fECfbb1B816B3236E9b8" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" - ProxyAdminOwner = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" - Guardian = "0xcE10372313Ca39Fbf75A09e7f4c0E57F070259f4" - Challenger = "0xcE10372313Ca39Fbf75A09e7f4c0E57F070259f4" - Proposer = "0x74BaD482a7f73C8286F50D8Aa03e53b7d24A5f3B" - UnsafeBlockSigner = "0xceED24B1Fd4A4393f6A9D2B137D9597dd5482569" - BatchSubmitter = "0xf8dB8Aba597fF36cCD16fECfbb1B816B3236E9b8" - AddressManager = "0x87630a802a3789463eC4b00f89b27b1e9f6b92e9" - L1CrossDomainMessengerProxy = "0xc76543A64666d9a073FaEF4e75F651c88e7DBC08" - L1ERC721BridgeProxy = "0x934Ab59Ef14b638653b1C0FEf7aB9a72186393DC" - L1StandardBridgeProxy = "0xe07eA0436100918F157DF35D01dCE5c11b16D1F1" - L2OutputOracleProxy = "0x5e76821C3c1AbB9fD6E310224804556C61D860e0" - OptimismMintableERC20FactoryProxy = "0x7a69a90d8ea11E9618855da55D09E6F953730686" - OptimismPortalProxy = "0x91493a61ab83b62943E6dCAa5475Dd330704Cc84" - SystemConfigProxy = "0x886B187C3D293B1449A3A0F23Ca9e2269E0f2664" - ProxyAdmin = "0xb570F4aD27e7De879A2E4F2F3DE27dBaBc20E9B9" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" - DelayedWETHProxy = "0x0000000000000000000000000000000000000000" - DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x0000000000000000000000000000000000000000" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0x0000000000000000000000000000000000000000" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "Binary Mainnet" - chain_id = 624 - public_rpc = "https://rpc.zero.thebinaryholdings.com" - sequencer_rpc = "https://sequencer.bnry.mainnet.zeeve.net" - explorer = "https://explorer.thebinaryholdings.com/" - superchain_level = 0 - batch_inbox_addr = "0xFF00000000000000000000000000000000000624" - canyon_time = 0 - delta_time = 0 - ecotone_time = 0 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - gas_paying_token = "0x04E9D7e336f79Cdab911b06133D3Ca2Cd0721ce3" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1719397463 - [superchains.chains.genesis.l1] - hash = "0xdcc5838ee3dd0af995c87bec9614a09f08dd8979014876b42fd7e3ae044dd8c4" - number = 20175246 - [superchains.chains.genesis.l2] - hash = "0xe222b4b07ee9c885d13ee341823c92aa449f9769ac68fb5f1e1d4e602a990a4a" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x7f9D9c1BCE1062E1077845eA39a0303429600a06" - overhead = "0x0000000000000000000000000000000000000000000000000000000000000000" - scalar = "0x010000000000000000000000000000000000000000000000000c5fc500000558" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0x25A6E7c6f3d0fE89A656Fcf065614B74E55099fF" - ProxyAdminOwner = "0x48EC051349dDc7E8baBafCBfe27696ECF2A8a8B3" - Guardian = "0x87aab081Ac9F8ce80fb048f23280DF019036BA1d" - Challenger = "0x79DdF0745D14783cDC2a05624c585Ddce07F4A02" - Proposer = "0x2b6cD940ABE0CAF2fd89155b99522548c00EBaB1" - UnsafeBlockSigner = "0xDbad225D1C0DaBc27f6a9d250dBb136413C0DFb4" - BatchSubmitter = "0x7f9D9c1BCE1062E1077845eA39a0303429600a06" - AddressManager = "0x8173904703995c6BbA59a42B8bBf8405F978758a" - L1CrossDomainMessengerProxy = "0x807d21e416434ae92c8E5bcA4d506781aFbBa380" - L1ERC721BridgeProxy = "0x1b396e4dC6ECB0be33CF01C5a34E1a3a7D03c378" - L1StandardBridgeProxy = "0xD1B30378CBF968E5525e8835219A5726A1e71D10" - L2OutputOracleProxy = "0x012f4baa6e0F5Ac4dFDF47BDdd9CF68a2B17821e" - OptimismMintableERC20FactoryProxy = "0xa641e14B685b5E652865e14A4fBc07e51371D124" - OptimismPortalProxy = "0x5ff88fcF8e9947f45F4cAf8FFd5231B5DdF05e0A" - SystemConfigProxy = "0x7aC7e5989EaC278B7BbfeF560871a2026baD472c" - ProxyAdmin = "0x38593Cce8FaB9887Ef9760f5F6aB3d6C595143cF" - SuperchainConfig = "0x34bb53D7C525114A27F0FE2aF91bdDAd186abb12" - AnchorStateRegistryProxy = "0x275Abd1eB1FBaAB40Dcef5f3A588e2dF65801edc" - DelayedWETHProxy = "0x161914F701d090824c1A8a0f4e5666938f12848d" - DisputeGameFactoryProxy = "0x0D7e0590c58e4aC9B14B3eD6163CF55223931699" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x4e66D89DDF5A9d86836ABb1d05Ff8fDb5aD32c9A" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0xB9fF3A5835144b0d2F4267A21e0c74458907c870" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "Lyra Chain" - chain_id = 957 - public_rpc = "https://rpc.lyra.finance" - sequencer_rpc = "https://rpc.lyra.finance" - explorer = "https://explorer.lyra.finance" - superchain_level = 0 - superchain_time = 0 - batch_inbox_addr = "0x5f7f7f6DB967F0ef10BdA0678964DBA185d16c50" - canyon_time = 1704992401 - delta_time = 1708560000 - ecotone_time = 1710374401 - fjord_time = 1720627201 - granite_time = 1726070401 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1700021615 - [superchains.chains.genesis.l1] - hash = "0x00b06b23108483a0b6af8ff726b5ed3f508b7986f72c12679b10d72c05839716" - number = 18574841 - [superchains.chains.genesis.l2] - hash = "0x047f535b3da7ad4f96d353b5a439740b7591413daee0e2f27dd3aabb24581af2" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x14e4E97bDc195d399Ad8E7FC14451C279FE04c8e" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" - ProxyAdminOwner = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" - Guardian = "0x91F4be0C264FAFA1fEd75c4440910Cba2cAd98e8" - Challenger = "0x91F4be0C264FAFA1fEd75c4440910Cba2cAd98e8" - Proposer = "0x03e820562ffd2e0390787caD706EaF1FF98C2608" - UnsafeBlockSigner = "0xB71B58FfE538628557433dbBfA08d45ee5a69B44" - BatchSubmitter = "0x14e4E97bDc195d399Ad8E7FC14451C279FE04c8e" - AddressManager = "0xC845F9C4004EB35a8bde8ad89C4760a9c0e65CAB" - L1CrossDomainMessengerProxy = "0x5456f02c08e9A018E42C39b351328E5AA864174A" - L1ERC721BridgeProxy = "0x6CC3268794c5d3E3d9d52adEfC748B59d536cb22" - L1StandardBridgeProxy = "0x61E44dC0dae6888B5a301887732217d5725B0bFf" - L2OutputOracleProxy = "0x1145E7848c8B64c6cab86Fd6D378733385c5C3Ba" - OptimismMintableERC20FactoryProxy = "0x08Dea366F26C25a08C8D1C3568ad07d1e587136d" - OptimismPortalProxy = "0x85eA9c11cf3D4786027F7FD08F4406b15777e5f8" - SystemConfigProxy = "0x0e4C4CDd01ceCB01070E9Fdfe7600871e4ae996e" - ProxyAdmin = "0x35d5D43271548c984662d4879FBc8e041Bc1Ff93" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" - DelayedWETHProxy = "0x0000000000000000000000000000000000000000" - DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x0000000000000000000000000000000000000000" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0x0000000000000000000000000000000000000000" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "Metal L2" - chain_id = 1750 - public_rpc = "https://rpc.metall2.com" - sequencer_rpc = "https://rpc.metall2.com" - explorer = "https://explorer.metall2.com" - superchain_level = 0 - standard_chain_candidate = true - superchain_time = 0 - batch_inbox_addr = "0xc83f7D9F2D4A76E81145849381ABA02602373723" - canyon_time = 0 - delta_time = 0 - ecotone_time = 0 - fjord_time = 1720627201 - granite_time = 1726070401 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1711563515 - [superchains.chains.genesis.l1] - hash = "0x2493565ce8472656b7c22377c8d4d8ef5d17f78392c799ca5f2429b01e2c159c" - number = 19527340 - [superchains.chains.genesis.l2] - hash = "0xd31c12ffff2d563897ad9a041c0d26790d635911bdbbfa589347fa955f75281e" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0xC94C243f8fb37223F3EB2f7961F7072602A51B8B" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" - ProxyAdminOwner = "0x5a0Aae59D09fccBdDb6C6CcEB07B7279367C3d2A" - Guardian = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" - Challenger = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" - Proposer = "0xC8187d40AD440328104A52BBed2D8Efc5ab1F1F6" - UnsafeBlockSigner = "0x4a65F5da5e80DEFfEA844eAa15CE130e80605dc5" - BatchSubmitter = "0xC94C243f8fb37223F3EB2f7961F7072602A51B8B" - AddressManager = "0xd4b1EC0DEc3C7F12abD3ec27B7514880ae1C3a37" - L1CrossDomainMessengerProxy = "0x0a47A44f1B2bb753474f8c830322554A96C9934D" - L1ERC721BridgeProxy = "0x50D700e97967F9115e3f999bDB263d69F6704680" - L1StandardBridgeProxy = "0x6d0f65D59b55B0FEC5d2d15365154DcADC140BF3" - L2OutputOracleProxy = "0x3B1F7aDa0Fcc26B13515af752Dd07fB1CAc11426" - OptimismMintableERC20FactoryProxy = "0x1aaab4E20d2e4Bb992b5BCA2125e8bd3588c8730" - OptimismPortalProxy = "0x3F37aBdE2C6b5B2ed6F8045787Df1ED1E3753956" - SystemConfigProxy = "0x7BD909970B0EEdcF078De6Aeff23ce571663b8aA" - ProxyAdmin = "0x37Ff0ae34dadA1A95A4251d10ef7Caa868c7AC99" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" - DelayedWETHProxy = "0x0000000000000000000000000000000000000000" - DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x0000000000000000000000000000000000000000" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0x0000000000000000000000000000000000000000" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "RACE Mainnet" - chain_id = 6805 - public_rpc = "https://racemainnet.io" - sequencer_rpc = "https://racemainnet.io" - explorer = "https://racescan.io/" - superchain_level = 0 - batch_inbox_addr = "0xFF00000000000000000000000000000000006805" - canyon_time = 0 - delta_time = 0 - ecotone_time = 0 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1720421591 - [superchains.chains.genesis.l1] - hash = "0xb6fd41e6c3515172c36d3912046264475eaad84c2c56e99d74f4abd1a75b63c9" - number = 20260129 - [superchains.chains.genesis.l2] - hash = "0xa864791943836c37b40ea688f3853f2198afb683a3e168d48bfa76c9896e3e65" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x8CDa8351236199AF7532baD53D683Ddd9B275d89" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0xBac1ad52745162c0aA3711fe88Df1Cc67034a3B9" - ProxyAdminOwner = "0x5A669B2193718F189b0576c0cdcedfEd6f40F9Ea" - Guardian = "0x2E7B9465B25C081c07274A31DbD05C6146f67961" - Challenger = "0x2E7B9465B25C081c07274A31DbD05C6146f67961" - Proposer = "0x88D58BFbCD70c25409b67117fC1CDfeFDA113a78" - UnsafeBlockSigner = "0x9b5639D472D6764b70F5046Ac0B13438718398E0" - BatchSubmitter = "0x8CDa8351236199AF7532baD53D683Ddd9B275d89" - AddressManager = "0x3d2BdE87466Cae97011702D2C305fd40EEBbbF0a" - L1CrossDomainMessengerProxy = "0xf54B2BAEF894cfF5511A5722Acaac0409F2F2d89" - L1ERC721BridgeProxy = "0x0f33D824d74180598311b3025095727BeA61f219" - L1StandardBridgeProxy = "0x680969A6c58183987c8126ca4DE6b59C6540Cd2a" - L2OutputOracleProxy = "0x8bF8442d49d52377d735a90F19657a29f29aA83c" - OptimismMintableERC20FactoryProxy = "0x1d1c4C89AD5FF486c3C67E3DD84A22CF05420711" - OptimismPortalProxy = "0x0485Ca8A73682B3D3f5ae98cdca1E5b512E728e9" - SystemConfigProxy = "0xCf6A32dB8b3313b3d439CE6909511c2c3415fa32" - ProxyAdmin = "0x9B3C6D1d33F1fd82Ebb8dFbE38dA162B329De191" - SuperchainConfig = "0xCB73B7348705a9F925643150Eb00350719380FF8" - AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" - DelayedWETHProxy = "0x0000000000000000000000000000000000000000" - DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x0000000000000000000000000000000000000000" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0x0000000000000000000000000000000000000000" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "Base" - chain_id = 8453 - public_rpc = "https://mainnet.base.org" - sequencer_rpc = "https://mainnet-sequencer.base.org" - explorer = "https://explorer.base.org" - superchain_level = 0 - standard_chain_candidate = true - superchain_time = 0 - batch_inbox_addr = "0xFf00000000000000000000000000000000008453" - canyon_time = 1704992401 - delta_time = 1708560000 - ecotone_time = 1710374401 - fjord_time = 1720627201 - granite_time = 1726070401 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1686789347 - [superchains.chains.genesis.l1] - hash = "0x5c13d307623a926cd31415036c8b7fa14572f9dac64528e857a470511fc30771" - number = 17481768 - [superchains.chains.genesis.l2] - hash = "0xf712aa9241cc24369b143cf6dce85f0902a9731e70d66818a3a5845b296c73dd" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x5050F69a9786F081509234F1a7F4684b5E5b76C9" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0x14536667Cd30e52C0b458BaACcB9faDA7046E056" - ProxyAdminOwner = "0x7bB41C3008B3f03FE483B28b8DB90e19Cf07595c" - Guardian = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" - Challenger = "0x6F8C5bA3F59ea3E76300E3BEcDC231D656017824" - Proposer = "0x642229f238fb9dE03374Be34B0eD8D9De80752c5" - UnsafeBlockSigner = "0xAf6E19BE0F9cE7f8afd49a1824851023A8249e8a" - BatchSubmitter = "0x5050F69a9786F081509234F1a7F4684b5E5b76C9" - AddressManager = "0x8EfB6B5c4767B09Dc9AA6Af4eAA89F749522BaE2" - L1CrossDomainMessengerProxy = "0x866E82a600A1414e583f7F13623F1aC5d58b0Afa" - L1ERC721BridgeProxy = "0x608d94945A64503E642E6370Ec598e519a2C1E53" - L1StandardBridgeProxy = "0x3154Cf16ccdb4C6d922629664174b904d80F2C35" - L2OutputOracleProxy = "0x56315b90c40730925ec5485cf004d835058518A0" - OptimismMintableERC20FactoryProxy = "0x05cc379EBD9B30BbA19C6fA282AB29218EC61D84" - OptimismPortalProxy = "0x49048044D57e1C92A77f79988d21Fa8fAF74E97e" - SystemConfigProxy = "0x73a79Fab69143498Ed3712e519A88a918e1f4072" - ProxyAdmin = "0x0475cBCAebd9CE8AfA5025828d5b98DFb67E059E" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" - DelayedWETHProxy = "0x0000000000000000000000000000000000000000" - DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x0000000000000000000000000000000000000000" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0x0000000000000000000000000000000000000000" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "Mode" - chain_id = 34443 - public_rpc = "https://mainnet.mode.network" - sequencer_rpc = "https://mainnet-sequencer.mode.network" - explorer = "https://explorer.mode.network" - superchain_level = 0 - standard_chain_candidate = true - superchain_time = 0 - batch_inbox_addr = "0x24E59d9d3Bd73ccC28Dc54062AF7EF7bFF58Bd67" - canyon_time = 1704992401 - delta_time = 1708560000 - ecotone_time = 1710374401 - fjord_time = 1720627201 - granite_time = 1726070401 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1700167583 - [superchains.chains.genesis.l1] - hash = "0xf9b1b22a7ef9d13f063ea467bcb70fb6e9f29698ecb7366a2cdf5af2165cacee" - number = 18586927 - [superchains.chains.genesis.l2] - hash = "0xb0f682e12fc555fd5ce8fce51a59a67d66a5b46be28611a168260a549dac8a9b" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x99199a22125034c808ff20f377d91187E8050F2E" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0x4a4962275DF8C60a80d3a25faEc5AA7De116A746" - ProxyAdminOwner = "0x5a0Aae59D09fccBdDb6C6CcEB07B7279367C3d2A" - Guardian = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" - Challenger = "0x309Fe2536d01867018D120b40e4676723C53A14C" - Proposer = "0x674F64D64Ddc198db83cd9047dF54BF89cCD0ddB" - UnsafeBlockSigner = "0xa7fA9CA4ac88686A542C0f830d7378eAB4A0278F" - BatchSubmitter = "0x99199a22125034c808ff20f377d91187E8050F2E" - AddressManager = "0x50eF494573f28Cad6B64C31b7a00Cdaa48306e15" - L1CrossDomainMessengerProxy = "0x95bDCA6c8EdEB69C98Bd5bd17660BaCef1298A6f" - L1ERC721BridgeProxy = "0x2901dA832a4D0297FF0691100A8E496626cc626D" - L1StandardBridgeProxy = "0x735aDBbE72226BD52e818E7181953f42E3b0FF21" - L2OutputOracleProxy = "0x4317ba146D4933D889518a3e5E11Fe7a53199b04" - OptimismMintableERC20FactoryProxy = "0x69216395A62dFb243C05EF4F1C27AF8655096a95" - OptimismPortalProxy = "0x8B34b14c7c7123459Cf3076b8Cb929BE097d0C07" - SystemConfigProxy = "0x5e6432F18Bc5d497B1Ab2288a025Fbf9D69E2221" - ProxyAdmin = "0x470d87b1dae09a454A43D1fD772A561a03276aB7" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" - DelayedWETHProxy = "0x0000000000000000000000000000000000000000" - DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x0000000000000000000000000000000000000000" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0x0000000000000000000000000000000000000000" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "Zora" - chain_id = 7777777 - public_rpc = "https://rpc.zora.energy" - sequencer_rpc = "https://rpc.zora.energy" - explorer = "https://explorer.zora.energy" - superchain_level = 0 - standard_chain_candidate = true - superchain_time = 0 - batch_inbox_addr = "0x6F54Ca6F6EdE96662024Ffd61BFd18f3f4e34DFf" - canyon_time = 1704992401 - delta_time = 1708560000 - ecotone_time = 1710374401 - fjord_time = 1720627201 - granite_time = 1726070401 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1686693839 - [superchains.chains.genesis.l1] - hash = "0xbdbd2847f7aa5f7cd1bd4c9f904057f4ba0b498c7e380199c01d240e3a41a84f" - number = 17473923 - [superchains.chains.genesis.l2] - hash = "0x47555a45a1af8d4728ca337a1e48375a83919b1ea16591e070a07388b7364e29" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x625726c858dBF78c0125436C943Bf4b4bE9d9033" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0xC72aE5c7cc9a332699305E29F68Be66c73b60542" - ProxyAdminOwner = "0x5a0Aae59D09fccBdDb6C6CcEB07B7279367C3d2A" - Guardian = "0x09f7150D8c019BeF34450d6920f6B3608ceFdAf2" - Challenger = "0xcA4571b1ecBeC86Ea2E660d242c1c29FcB55Dc72" - Proposer = "0x48247032092e7b0ecf5dEF611ad89eaf3fC888Dd" - UnsafeBlockSigner = "0x3Dc8Dfd0709C835cAd15a6A27e089FF4cF4C9228" - BatchSubmitter = "0x625726c858dBF78c0125436C943Bf4b4bE9d9033" - AddressManager = "0xEF8115F2733fb2033a7c756402Fc1deaa56550Ef" - L1CrossDomainMessengerProxy = "0xdC40a14d9abd6F410226f1E6de71aE03441ca506" - L1ERC721BridgeProxy = "0x83A4521A3573Ca87f3a971B169C5A0E1d34481c3" - L1StandardBridgeProxy = "0x3e2Ea9B92B7E48A52296fD261dc26fd995284631" - L2OutputOracleProxy = "0x9E6204F750cD866b299594e2aC9eA824E2e5f95c" - OptimismMintableERC20FactoryProxy = "0xc52BC7344e24e39dF1bf026fe05C4e6E23CfBcFf" - OptimismPortalProxy = "0x1a0ad011913A150f69f6A19DF447A0CfD9551054" - SystemConfigProxy = "0xA3cAB0126d5F504B071b81a3e8A2BBBF17930d86" - ProxyAdmin = "0xD4ef175B9e72cAEe9f1fe7660a6Ec19009903b49" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" - DelayedWETHProxy = "0x0000000000000000000000000000000000000000" - DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x0000000000000000000000000000000000000000" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0x0000000000000000000000000000000000000000" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - -[[superchains]] - name = "sepolia" - [superchains.config] - name = "Sepolia" - protocol_versions_addr = "0x79ADD5713B383DAa0a138d3C4780C7A1804a8090" - superchain_config_addr = "0xC2Be75506d5724086DEB7245bd260Cc9753911Be" - [superchains.config.l1] - chain_id = 11155111 - public_rpc = "https://ethereum-sepolia-rpc.publicnode.com" - explorer = "https://sepolia.etherscan.io" - - [[superchains.chains]] - name = "Mode Testnet" - chain_id = 919 - public_rpc = "https://sepolia.mode.network" - sequencer_rpc = "https://sepolia.mode.network" - explorer = "https://sepolia.explorer.mode.network" - superchain_level = 0 - standard_chain_candidate = true - superchain_time = 1703203200 - batch_inbox_addr = "0xcDDaE6148dA1E003C230E4527f9baEdc8a204e7E" - canyon_time = 1703203200 - delta_time = 1703203200 - ecotone_time = 1708534800 - fjord_time = 1716998400 - granite_time = 1723478400 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1687867932 - [superchains.chains.genesis.l1] - hash = "0x4370cafe528a1b8f2aaffc578094731daf69ff82fd9edc30d2d842d3763f3410" - number = 3778382 - [superchains.chains.genesis.l2] - hash = "0x13c352562289a88ed33087a51b6b6c859a27709c8555c9def7cb9757c043acad" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x4e6BD53883107B063c502dDd49F9600Dc51b3DDc" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C" - ProxyAdminOwner = "0x1Eb2fFc903729a0F03966B917003800b145F56E2" - Guardian = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" - Challenger = "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7" - Proposer = "0xe9e08A478e3a773c1B5D59014A0FDb901e6d1d69" - UnsafeBlockSigner = "0x93A14E6894eEB4FF6a373E1Ad4f498c3a207afe4" - BatchSubmitter = "0x4e6BD53883107B063c502dDd49F9600Dc51b3DDc" - AddressManager = "0x83D45725d6562d8CD717673D6bb4c67C07dC1905" - L1CrossDomainMessengerProxy = "0xc19a60d9E8C27B9A43527c3283B4dd8eDC8bE15C" - L1ERC721BridgeProxy = "0x015a8c2e0a5fEd579dbb05fd290e413Adc6FC24A" - L1StandardBridgeProxy = "0xbC5C679879B2965296756CD959C3C739769995E2" - L2OutputOracleProxy = "0x2634BD65ba27AB63811c74A63118ACb312701Bfa" - OptimismMintableERC20FactoryProxy = "0x00F7ab8c72D32f55cFf15e8901C2F9f2BF29A3C0" - OptimismPortalProxy = "0x320e1580effF37E008F1C92700d1eBa47c1B23fD" - SystemConfigProxy = "0x15cd4f6e0CE3B4832B33cB9c6f6Fe6fc246754c2" - ProxyAdmin = "0xE7413127F29E050Df65ac3FC9335F85bB10091AE" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" - DelayedWETHProxy = "0x0000000000000000000000000000000000000000" - DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x0000000000000000000000000000000000000000" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0x0000000000000000000000000000000000000000" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "Metal L2 Testnet" - chain_id = 1740 - public_rpc = "https://testnet.rpc.metall2.com" - sequencer_rpc = "https://testnet.rpc.metall2.com" - explorer = "https://testnet.explorer.metall2.com" - superchain_level = 0 - standard_chain_candidate = true - batch_inbox_addr = "0x24567B64a86A4c966655fba6502a93dFb701E316" - canyon_time = 1708129622 - delta_time = 1708385400 - ecotone_time = 1708534800 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1708129620 - [superchains.chains.genesis.l1] - hash = "0x6a10927c70985f75898c48235b620acb2a48e9c777a40022f9dbad1b0c96a9c1" - number = 5304030 - [superchains.chains.genesis.l2] - hash = "0xd24cf8e46b189b0c128dab4e46168520e3a4cdd390b239e8cc1e5abd22a629ae" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0xdb80Eca386AC72a55510e33CF9CF7533e75916eE" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C" - ProxyAdminOwner = "0x1Eb2fFc903729a0F03966B917003800b145F56E2" - Guardian = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" - Challenger = "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7" - Proposer = "0x0000000000000000000000000000000000000000" - UnsafeBlockSigner = "0x0000000000000000000000000000000000000000" - BatchSubmitter = "0xdb80Eca386AC72a55510e33CF9CF7533e75916eE" - AddressManager = "0x394f844B9A0FC876935d1b0b791D9e94Ad905e8b" - L1CrossDomainMessengerProxy = "0x5D335Aa7d93102110879e3B54985c5F08146091E" - L1ERC721BridgeProxy = "0x5d6cE6917dBeeacF010c96BfFdaBE89e33a30309" - L1StandardBridgeProxy = "0x21530aAdF4DCFb9c477171400E40d4ef615868BE" - L2OutputOracleProxy = "0x75a6B961c8da942Ee03CA641B09C322549f6FA98" - OptimismMintableERC20FactoryProxy = "0x49Ff2C4be882298e8CA7DeCD195c207c42B45F66" - OptimismPortalProxy = "0x01D4dfC994878682811b2980653D03E589f093cB" - SystemConfigProxy = "0x5D63A8Dc2737cE771aa4a6510D063b6Ba2c4f6F2" - ProxyAdmin = "0xF7Bc4b3a78C7Dd8bE9B69B3128EEB0D6776Ce18A" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" - DelayedWETHProxy = "0x0000000000000000000000000000000000000000" - DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x0000000000000000000000000000000000000000" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0x0000000000000000000000000000000000000000" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "RACE Testnet" - chain_id = 6806 - public_rpc = "https://racetestnet.io" - sequencer_rpc = "https://racetestnet.io" - explorer = "https://testnet.racescan.io/" - superchain_level = 0 - batch_inbox_addr = "0xff00000000000000000000000000000000006806" - canyon_time = 0 - delta_time = 0 - ecotone_time = 0 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1719646560 - [superchains.chains.genesis.l1] - hash = "0x28dd1dd74080560ef0b02f8f1ae31d1be75b01a70a5be6ef22e673cec538770f" - number = 6210400 - [superchains.chains.genesis.l2] - hash = "0x994d67464c3368b8eb6f9770087399486b25d721a1868b95bb37de327b49ab89" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x584D61A30C7Ef1E8D547eE02099dADC487f49889" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0xE6869aF6c871614df04902870Bb13d4505E1586c" - ProxyAdminOwner = "0xAc78E9B3Aa9373AE4bE2Ba5Bc9F716d7A746A65E" - Guardian = "0xE6869aF6c871614df04902870Bb13d4505E1586c" - Challenger = "0xE6869aF6c871614df04902870Bb13d4505E1586c" - Proposer = "0x5a145E3F466FD6cC095214C700359df7894BaD21" - UnsafeBlockSigner = "0x89eA88ef4AC23f4C7Fdc611Fc9cD1c50DF702C2C" - BatchSubmitter = "0x584D61A30C7Ef1E8D547eE02099dADC487f49889" - AddressManager = "0x1B573Db1000eA419B6dE8eB482C6d394179Bd1A3" - L1CrossDomainMessengerProxy = "0xdaeab17598938A4f27E50AC771249Ad7df12Ea7D" - L1ERC721BridgeProxy = "0xBafb1a6e54e7750aF29489D65888d1c96Dfd66Df" - L1StandardBridgeProxy = "0x289179e9d43A35D47239456251F9c2fdbf9fbeA2" - L2OutputOracleProxy = "0xccac2B8FFc4f778242105F3a9E6B3Ae3F827fC6a" - OptimismMintableERC20FactoryProxy = "0xbd023e7F08AE0274dCEd397D4B6630D697aC738A" - OptimismPortalProxy = "0xF2891fc6819CDd6BD9221874619BB03A6277d72A" - SystemConfigProxy = "0x07e7A3F25aA73dA15bc19B71FEF8f5511342a409" - ProxyAdmin = "0x4a0E8415e3eB85E7393445FD8E588283b62216C8" - SuperchainConfig = "0x1696a64C7F170E46D32088E8eC29193300C35817" - AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" - DelayedWETHProxy = "0x0000000000000000000000000000000000000000" - DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x0000000000000000000000000000000000000000" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0x0000000000000000000000000000000000000000" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "Base Sepolia Testnet" - chain_id = 84532 - public_rpc = "https://sepolia.base.org" - sequencer_rpc = "https://sepolia-sequencer.base.org" - explorer = "https://sepolia-explorer.base.org" - superchain_level = 0 - standard_chain_candidate = true - superchain_time = 0 - batch_inbox_addr = "0xfF00000000000000000000000000000000084532" - canyon_time = 1699981200 - delta_time = 1703203200 - ecotone_time = 1708534800 - fjord_time = 1716998400 - granite_time = 1723478400 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 10 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1695768288 - [superchains.chains.genesis.l1] - hash = "0xcac9a83291d4dec146d6f7f69ab2304f23f5be87b1789119a0c5b1e4482444ed" - number = 4370868 - [superchains.chains.genesis.l2] - hash = "0x0dcc9e089e30b90ddfc55be9a37dd15bc551aeee999d2e2b51414c54eaf934e4" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x6CDEbe940BC0F26850285cacA097C11c33103E47" - overhead = "0x0000000000000000000000000000000000000000000000000000000000000834" - scalar = "0x00000000000000000000000000000000000000000000000000000000000f4240" - gasLimit = 25000000 - [superchains.chains.addresses] - SystemConfigOwner = "0x0fe884546476dDd290eC46318785046ef68a0BA9" - ProxyAdminOwner = "0x0fe884546476dDd290eC46318785046ef68a0BA9" - Guardian = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" - Challenger = "0xDa3037Ff70Ac92CD867c683BD807e5A484857405" - Proposer = "0x20044a0d104E9e788A0C984A2B7eAe615afD046b" - UnsafeBlockSigner = "0xb830b99c95Ea32300039624Cb567d324D4b1D83C" - BatchSubmitter = "0xfc56E7272EEBBBA5bC6c544e159483C4a38f8bA3" - AddressManager = "0x709c2B8ef4A9feFc629A8a2C1AF424Dc5BD6ad1B" - L1CrossDomainMessengerProxy = "0xC34855F4De64F1840e5686e64278da901e261f20" - L1ERC721BridgeProxy = "0x21eFD066e581FA55Ef105170Cc04d74386a09190" - L1StandardBridgeProxy = "0xfd0Bf71F60660E2f608ed56e1659C450eB113120" - L2OutputOracleProxy = "0x0000000000000000000000000000000000000000" - OptimismMintableERC20FactoryProxy = "0xb1efB9650aD6d0CC1ed3Ac4a0B7f1D5732696D37" - OptimismPortalProxy = "0x49f53e41452C74589E85cA1677426Ba426459e85" - SystemConfigProxy = "0xf272670eb55e895584501d564AfEB048bEd26194" - ProxyAdmin = "0x0389E59Aa0a41E4A413Ae70f0008e76CAA34b1F3" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x4C8BA32A5DAC2A720bb35CeDB51D6B067D104205" - DelayedWETHProxy = "0x7698b262B7a534912c8366dD8a531672deEC634e" - DisputeGameFactoryProxy = "0xd6E6dBf4F7EA0ac412fD8b65ED297e64BB7a06E1" - FaultDisputeGame = "0x8A9bA50a785c3868bEf1FD4924b640A5e0ed54CF" - MIPS = "0xFF760A87E41144b336E29b6D4582427dEBdB6dee" - PermissionedDisputeGame = "0x3f5c770f17A6982d2B3Ac77F6fDC93BFE0330E17" - PreimageOracle = "0x627F825CBd48c4102d36f287be71f4234426b9e4" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "OP Sepolia Testnet" - chain_id = 11155420 - public_rpc = "https://sepolia.optimism.io" - sequencer_rpc = "https://sepolia-sequencer.optimism.io" - explorer = "https://sepolia-optimistic.etherscan.io" - superchain_level = 1 - superchain_time = 0 - batch_inbox_addr = "0xff00000000000000000000000000000011155420" - canyon_time = 1699981200 - delta_time = 1703203200 - ecotone_time = 1708534800 - fjord_time = 1716998400 - granite_time = 1723478400 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1691802540 - [superchains.chains.genesis.l1] - hash = "0x48f520cf4ddaf34c8336e6e490632ea3cf1e5e93b0b2bc6e917557e31845371b" - number = 4071408 - [superchains.chains.genesis.l2] - hash = "0x102de6ffb001480cc9b8b548fd05c34cd4f46ae4aa91759393db90ea0409887d" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x8F23BB38F531600e5d8FDDaAEC41F13FaB46E98c" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301" - ProxyAdminOwner = "0x1Eb2fFc903729a0F03966B917003800b145F56E2" - Guardian = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" - Challenger = "0xfd1D2e729aE8eEe2E146c033bf4400fE75284301" - Proposer = "0x49277EE36A024120Ee218127354c4a3591dc90A9" - UnsafeBlockSigner = "0x57CACBB0d30b01eb2462e5dC940c161aff3230D3" - BatchSubmitter = "0x8F23BB38F531600e5d8FDDaAEC41F13FaB46E98c" - AddressManager = "0x9bFE9c5609311DF1c011c47642253B78a4f33F4B" - L1CrossDomainMessengerProxy = "0x58Cc85b8D04EA49cC6DBd3CbFFd00B4B8D6cb3ef" - L1ERC721BridgeProxy = "0xd83e03D576d23C9AEab8cC44Fa98d058D2176D1f" - L1StandardBridgeProxy = "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1" - L2OutputOracleProxy = "0x0000000000000000000000000000000000000000" - OptimismMintableERC20FactoryProxy = "0x868D59fF9710159C2B330Cc0fBDF57144dD7A13b" - OptimismPortalProxy = "0x16Fc5058F25648194471939df75CF27A2fdC48BC" - SystemConfigProxy = "0x034edD2A225f7f429A63E0f1D2084B9E0A93b538" - ProxyAdmin = "0x189aBAAaa82DfC015A588A7dbaD6F13b1D3485Bc" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x218CD9489199F321E1177b56385d333c5B598629" - DelayedWETHProxy = "0xF3D833949133e4E4D3551343494b34079598EA5a" - DisputeGameFactoryProxy = "0x05F9613aDB30026FFd634f38e5C4dFd30a197Fa1" - FaultDisputeGame = "0xD5Bc8c45692aada756f2d68f0a2002d6Bf130C42" - MIPS = "0xFF760A87E41144b336E29b6D4582427dEBdB6dee" - PermissionedDisputeGame = "0xBEA4384faCBcf51279962fbCFb8f16F9eD2fe0C6" - PreimageOracle = "0x627F825CBd48c4102d36f287be71f4234426b9e4" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "Zora Sepolia Testnet" - chain_id = 999999999 - public_rpc = "https://sepolia.rpc.zora.energy" - sequencer_rpc = "https://sepolia.rpc.zora.energy" - explorer = "https://sepolia.explorer.zora.energy" - superchain_level = 0 - standard_chain_candidate = true - superchain_time = 0 - batch_inbox_addr = "0xCd734290E4bd0200dAC631c7D4b9E8a33234e91f" - canyon_time = 1699981200 - delta_time = 1703203200 - ecotone_time = 1708534800 - fjord_time = 1716998400 - granite_time = 1723478400 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1698080004 - [superchains.chains.genesis.l1] - hash = "0xf782446a2487d900addb5d466a8597c7c543b59fa9aaa154d413830238f8798a" - number = 4548041 - [superchains.chains.genesis.l2] - hash = "0x8b17d2d52564a5a90079d9c860e1386272579e87b17ea27a3868513f53facd74" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x3Cd868E221A3be64B161D596A7482257a99D857f" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C" - ProxyAdminOwner = "0x1Eb2fFc903729a0F03966B917003800b145F56E2" - Guardian = "0x7a50f00e8D05b95F98fE38d8BeE366a7324dCf7E" - Challenger = "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7" - Proposer = "0xe8326a5839175dE7f467e66D8bB443aa70DA1c3e" - UnsafeBlockSigner = "0x3609513933100689bd1f84782529A99239842344" - BatchSubmitter = "0x3Cd868E221A3be64B161D596A7482257a99D857f" - AddressManager = "0x27c9392144DFcB6dab113F737356C32435cD1D55" - L1CrossDomainMessengerProxy = "0x1bDBC0ae22bEc0c2f08B4dd836944b3E28fe9b7A" - L1ERC721BridgeProxy = "0x16B0a4f451c4CB567703367e587E15Ac108e4311" - L1StandardBridgeProxy = "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB" - L2OutputOracleProxy = "0x2615B481Bd3E5A1C0C7Ca3Da1bdc663E8615Ade9" - OptimismMintableERC20FactoryProxy = "0x5F3bdd57f01e88cE2F88f00685D30D6eb51A187c" - OptimismPortalProxy = "0xeffE2C6cA9Ab797D418f0D91eA60807713f3536f" - SystemConfigProxy = "0xB54c7BFC223058773CF9b739cC5bd4095184Fb08" - ProxyAdmin = "0xE17071F4C216Eb189437fbDBCc16Bb79c4efD9c2" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" - DelayedWETHProxy = "0x0000000000000000000000000000000000000000" - DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x0000000000000000000000000000000000000000" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0x0000000000000000000000000000000000000000" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - -[[superchains]] - name = "sepolia-dev-0" - [superchains.config] - name = "Sepolia Dev 0" - protocol_versions_addr = "0x252CbE9517F731C618961D890D534183822dcC8d" - superchain_config_addr = "0x02d91Cf852423640d93920BE0CAdceC0E7A00FA7" - [superchains.config.l1] - chain_id = 11155111 - public_rpc = "https://ethereum-sepolia-rpc.publicnode.com" - explorer = "https://sepolia.etherscan.io" - - [[superchains.chains]] - name = "OP Labs Sepolia devnet 0" - chain_id = 11155421 - public_rpc = "" - sequencer_rpc = "" - explorer = "" - superchain_level = 0 - superchain_time = 0 - batch_inbox_addr = "0xFf00000000000000000000000000000011155421" - canyon_time = 0 - delta_time = 0 - ecotone_time = 1706634000 - fjord_time = 1715961600 - granite_time = 1723046400 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1706484048 - [superchains.chains.genesis.l1] - hash = "0x5639be97000fec7131a880b19b664cae43f975c773f628a08a9bb658c2a68df0" - number = 5173577 - [superchains.chains.genesis.l2] - hash = "0x027ae1f4f9a441f9c8a01828f3b6d05803a0f524c07e09263264a38b755f804b" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x19CC7073150D9f5888f09E0e9016d2a39667df14" - overhead = "0x00000000000000000000000000000000000000000000000000000000000000bc" - scalar = "0x00000000000000000000000000000000000000000000000000000000000a6fe0" - gasLimit = 30000000 - [superchains.chains.addresses] - SystemConfigOwner = "0x8c20c40180751d93E939DDDee3517AE0d1EBeAd2" - ProxyAdminOwner = "0x4377BB0F0103992b31eC12b4d796a8687B8dC8E9" - Guardian = "0x8c20c40180751d93E939DDDee3517AE0d1EBeAd2" - Challenger = "0x8c20c40180751d93E939DDDee3517AE0d1EBeAd2" - Proposer = "0x95014c45078354Ff839f14192228108Eac82E00A" - UnsafeBlockSigner = "0xa95B83e39AA78B00F12fe431865B563793D97AF5" - BatchSubmitter = "0x19CC7073150D9f5888f09E0e9016d2a39667df14" - AddressManager = "0x3eb579b25F6b9547e0073c848389a768FD382296" - L1CrossDomainMessengerProxy = "0x18e72C15FEE4e995454b919EfaA61D8f116F82dd" - L1ERC721BridgeProxy = "0x1bb726658E039E8a9A4ac21A41fE5a0704760461" - L1StandardBridgeProxy = "0x6D8bC564EF04AaF355a10c3eb9b00e349dd077ea" - L2OutputOracleProxy = "0x0000000000000000000000000000000000000000" - OptimismMintableERC20FactoryProxy = "0xA16b8db3b5Cdbaf75158F34034B0537e528E17e2" - OptimismPortalProxy = "0x76114bd29dFcC7a9892240D317E6c7C2A281Ffc6" - SystemConfigProxy = "0xa6b72407e2dc9EBF84b839B69A24C88929cf20F7" - ProxyAdmin = "0x18d890A46A3556e7F36f28C79F6157BC7a59f867" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x03b82AE60989863BCEb0BbD442A70568e5AefB85" - DelayedWETHProxy = "0xE99696a028171e31a72828A196C27c2Dd670E1aa" - DisputeGameFactoryProxy = "0x2419423C72998eb1c6c15A235de2f112f8E38efF" - FaultDisputeGame = "0x54416A2E28E8cbC761fbce0C7f107307991282e5" - MIPS = "0xceDE5949A189aC60F41F1385a86DBce7Bd3B1943" - PermissionedDisputeGame = "0x50573970b291726B881b204eD9F3c1D507e504cD" - PreimageOracle = "0xB73342DdD69620e5Ab2Cc604Dad46434C2338025" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" - - [[superchains.chains]] - name = "Base devnet 0" - chain_id = 11763072 - public_rpc = "" - sequencer_rpc = "" - explorer = "" - superchain_level = 0 - superchain_time = 1706634000 - batch_inbox_addr = "0xfF00000000000000000000000000000011763072" - canyon_time = 1698436800 - delta_time = 1706555000 - ecotone_time = 1706634000 - fjord_time = 1715961600 - granite_time = 1723046400 - block_time = 2 - seq_window_size = 3600 - max_sequencer_drift = 600 - data_availability_type = "eth-da" - [superchains.chains.optimism] - eip1559_elasticity = 6 - eip1559_denominator = 50 - eip1559_denominator_canyon = 250 - [superchains.chains.genesis] - l2_time = 1695433056 - [superchains.chains.genesis.l1] - hash = "0x86252c512dc5bd7201d0532b31d50696ba84344a7cda545e04a98073a8e13d87" - number = 4344216 - [superchains.chains.genesis.l2] - hash = "0x1ab91449a7c65b8cd6c06f13e2e7ea2d10b6f9cbf5def79f362f2e7e501d2928" - number = 0 - [superchains.chains.genesis.system_config] - batcherAddress = "0x212dD524932bC43478688F91045F2682913ad8EE" - overhead = "0x0000000000000000000000000000000000000000000000000000000000000834" - scalar = "0x00000000000000000000000000000000000000000000000000000000000f4240" - gasLimit = 25000000 - [superchains.chains.addresses] - SystemConfigOwner = "0xAf6E0E871f38c7B653700F7CbAEDafaa2784D430" - ProxyAdminOwner = "0xAf6E0E871f38c7B653700F7CbAEDafaa2784D430" - Guardian = "0x4F43c7422a9b2AC4BC6145Bd4eE206EA73cF8266" - Challenger = "0x5a533AaAC6cd81605b301a1077BC393A94658B6D" - Proposer = "0xf99C2Da4822Af652fe1BF55F99713980efe5D261" - UnsafeBlockSigner = "0xfd7bc3C58Fe4D4296F11F7843ebbA84D729A24B9" - BatchSubmitter = "0x7A43fD33e42054C965eE7175dd4590D2BDba79cB" - AddressManager = "0x882a60911d00867Fe4ea632C479cc48e583A8D69" - L1CrossDomainMessengerProxy = "0x2cbD403d5BA3949D24ee4dF57805eaC612C2662f" - L1ERC721BridgeProxy = "0xc3016ED03E087d092d576B585F5222fFD9cadc10" - L1StandardBridgeProxy = "0x5638e55db5Fcf7A58df525F1098E8569C8DbA80c" - L2OutputOracleProxy = "0xB5901509329307E3f910f333Fa9C4B4A8EE7CE1A" - OptimismMintableERC20FactoryProxy = "0xEAa11178375e6B1078d815d6F9F85cBbb69b09Cd" - OptimismPortalProxy = "0x579c82A835B884336B632eeBeCC78FA08D3291Ec" - SystemConfigProxy = "0x7F67DC4959cb3E532B10A99F41bDD906C46FdFdE" - ProxyAdmin = "0xC5aE9023bFA79124ffA50169E1423E733D0166f1" - SuperchainConfig = "0x0000000000000000000000000000000000000000" - AnchorStateRegistryProxy = "0x0000000000000000000000000000000000000000" - DelayedWETHProxy = "0x0000000000000000000000000000000000000000" - DisputeGameFactoryProxy = "0x0000000000000000000000000000000000000000" - FaultDisputeGame = "0x0000000000000000000000000000000000000000" - MIPS = "0x0000000000000000000000000000000000000000" - PermissionedDisputeGame = "0x0000000000000000000000000000000000000000" - PreimageOracle = "0x0000000000000000000000000000000000000000" - DAChallengeAddress = "0x0000000000000000000000000000000000000000" diff --git a/superchain/internal/codegen/main.go b/superchain/internal/codegen/main.go index d021a0a04..a04b342c3 100644 --- a/superchain/internal/codegen/main.go +++ b/superchain/internal/codegen/main.go @@ -103,9 +103,9 @@ func main() { // Write all chain configs to a single file type Superchain struct { - Name string `toml:"name"` - Config SuperchainConfig `toml:"config"` - ChainConfigs []ChainConfig `toml:"chains"` + Name string `json:"name" toml:"name"` + Config SuperchainConfig `json:"config" toml:"config"` + ChainConfigs []ChainConfig `json:"chains" toml:"chains"` } superchains := make([]Superchain, 0) for _, sc := range Superchains { @@ -130,27 +130,20 @@ func main() { return superchains[i].Config.Name < superchains[j].Config.Name }) if len(superchains) != 0 { - var buf bytes.Buffer type FullSuperchains struct { - Chains []Superchain `toml:"superchains"` + Chains []Superchain `json:"superchains" toml:"superchains"` } - if err := toml.NewEncoder(&buf).Encode(FullSuperchains{Chains: superchains}); err != nil { - panic(fmt.Errorf("failed to marshal toml: %w", err)) + superchainBytes, err := json.MarshalIndent(FullSuperchains{Chains: superchains}, "", " ") + if err != nil { + panic(err) } - // Prepend an autogenerated header. - header := []byte(`############################################## -# DO NOT EDIT - THIS FILE IS AUTOGENERATED # -# DO NOT REMOVE - USED BY BINDINGS # -############################################## -`) - // Write configs.toml file to the top-level directory. - buf = *bytes.NewBuffer(append(header, buf.Bytes()...)) - err = os.WriteFile(filepath.Join(repositoryRoot, "superchain/configs/configs.toml"), buf.Bytes(), 0o644) + // Write configs.json file to the top-level directory. + err = os.WriteFile(filepath.Join(repositoryRoot, "superchain/configs/configs.json"), superchainBytes, 0o644) if err != nil { panic(err) } - fmt.Println("Wrote configs.toml file") + fmt.Println("Wrote configs.json file") } // Marshal to JSON From cece7a737cafa2f25b7eb19cc0e66d6f3bd497d4 Mon Sep 17 00:00:00 2001 From: George Knee Date: Wed, 4 Sep 2024 16:42:58 +0100 Subject: [PATCH 23/30] add genesis validation metadata for mode sepolia (#546) * add genesis validation metadata for mode sepolia * update mode sepolia deploy-config --- .../validation-inputs/919/deploy-config.json | 43 +++++++++++++++++++ .../genesis/validation-inputs/919/meta.toml | 4 ++ 2 files changed, 47 insertions(+) create mode 100644 validation/genesis/validation-inputs/919/deploy-config.json create mode 100644 validation/genesis/validation-inputs/919/meta.toml diff --git a/validation/genesis/validation-inputs/919/deploy-config.json b/validation/genesis/validation-inputs/919/deploy-config.json new file mode 100644 index 000000000..d43023a63 --- /dev/null +++ b/validation/genesis/validation-inputs/919/deploy-config.json @@ -0,0 +1,43 @@ +{ + "l1StartingBlockTag": "0x39a74e", + "l1ChainID": 11155111, + "l2ChainID": 919, + "l2BlockTime": 2, + "finalizationPeriodSeconds": 180, + "systemConfigOwner": "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C", + "finalSystemOwner": "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C", + "controller": "0x9198DCa1e7Eb3728b43673f13eb66D1644CCE646", + "baseFeeVaultRecipient": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "l1FeeVaultRecipient": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "sequencerFeeVaultRecipient": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "governanceTokenOwner": "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C", + "governanceTokenSymbol": "OP", + "governanceTokenName": "Optimism", + "maxSequencerDrift": 600, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0x93A14E6894eEB4FF6a373E1Ad4f498c3a207afe4", + "optimismL2FeeRecipient": "0x0205b122b42edFA846fbe8a133184c4309616DC0", + "batchInboxAddress": "0xcDDaE6148dA1E003C230E4527f9baEdc8a204e7E", + "batchSenderAddress": "0x4e6BD53883107B063c502dDd49F9600Dc51b3DDc", + "l2GenesisRegolithTimeOffset": "0x0", + "portalGuardian": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "l2OutputOracleSubmissionInterval": 180, + "l2OutputOracleStartingTimestamp": -1, + "l2OutputOracleProposer": "0xe9e08A478e3a773c1B5D59014A0FDb901e6d1d69", + "l2OutputOracleOwner": "0x542C6b7Fd3a029D5eD2d3ce97056F9A479c4ba6C", + "l2GenesisBlockGasLimit": "0x1c9c380", + "fundDevAccounts": false, + "gasPriceOracleOverhead": 188, + "gasPriceOracleScalar": 684000, + "eip1559Denominator": 50, + "eip1559Elasticity": 6, + "proxyAdmin": "0x151900121E29c914d790fC9Daa08E2baAC054cAf", + "proxyAdminOwner": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "optimismBaseFeeRecipient": "0x2a7351c95099E3F68D6913F36A6389F77918B662", + "optimismL1FeeRecipient": "0x5D2B189183D159a7053339FC0e6F488B7422c7A6", + "l2CrossDomainMessengerOwner": "0xb9F8C5782bEfdea6E41f7A2B59869eFd39Aa0cF1", + "gasPriceOracleOwner": "0x70915523498aD856DD5d46182C8799e5BC279E0a", + "l2OutputOracleChallenger": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7" +} diff --git a/validation/genesis/validation-inputs/919/meta.toml b/validation/genesis/validation-inputs/919/meta.toml new file mode 100644 index 000000000..61deb5bc7 --- /dev/null +++ b/validation/genesis/validation-inputs/919/meta.toml @@ -0,0 +1,4 @@ +genesis_creation_commit = "75c00a5091e43cc50d9b33381a166c68c6a465cd" +monorepo_build_command = "pnpm" +node_version = "18.12.1" +genesis_creation_command = "opnode1" From 9decb08f64c8de612292518d14bcbfb5997cf296 Mon Sep 17 00:00:00 2001 From: George Knee Date: Wed, 4 Sep 2024 21:12:01 +0100 Subject: [PATCH 24/30] add validation metadata for zora sepolia (#547) --- .../999999999/deploy-config.json | 51 +++++++++++++++++++ .../validation-inputs/999999999/meta.toml | 4 ++ 2 files changed, 55 insertions(+) create mode 100644 validation/genesis/validation-inputs/999999999/deploy-config.json create mode 100644 validation/genesis/validation-inputs/999999999/meta.toml diff --git a/validation/genesis/validation-inputs/999999999/deploy-config.json b/validation/genesis/validation-inputs/999999999/deploy-config.json new file mode 100644 index 000000000..3c446d464 --- /dev/null +++ b/validation/genesis/validation-inputs/999999999/deploy-config.json @@ -0,0 +1,51 @@ +{ + "l1StartingBlockTag": "0xf782446a2487d900addb5d466a8597c7c543b59fa9aaa154d413830238f8798a", + "l1ChainID": 11155111, + "l2ChainID": 999999999, + "l2BlockTime": 2, + "l1BlockTime": 12, + "finalizationPeriodSeconds": 604800, + "systemConfigOwner": "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C", + "finalSystemOwner": "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C", + "controller": "0x7e0C990bd3a2E4e826102f35F2B2447069D3f0a7", + "baseFeeVaultRecipient": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "l1FeeVaultRecipient": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "sequencerFeeVaultRecipient": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "governanceTokenOwner": "0x23BA22Dd7923F3a3f2495bB32a6f3c9b9CD1EC6C", + "governanceTokenSymbol": "OP", + "governanceTokenName": "Optimism", + "maxSequencerDrift": 600, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + "p2pSequencerAddress": "0x3609513933100689bd1f84782529A99239842344", + "optimismL2FeeRecipient": "0xCb4Ba05b7f1F66B0F19Ae26561F6a3694a95768a", + "batchInboxAddress": "0xCd734290E4bd0200dAC631c7D4b9E8a33234e91f", + "batchSenderAddress": "0x3Cd868E221A3be64B161D596A7482257a99D857f", + "l2GenesisRegolithTimeOffset": "0x0", + "portalGuardian": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "l2OutputOracleSubmissionInterval": 180, + "l2OutputOracleStartingTimestamp": -1, + "l2OutputOracleStartingBlockNumber": 0, + "l2OutputOracleProposer": "0xe8326a5839175dE7f467e66D8bB443aa70DA1c3e", + "l2OutputOracleOwner": "0x13A8390A0e77f3296077Ff42d5B6B068a74dF1e9", + "sequencerFeeVaultWithdrawalNetwork": 0, + "baseFeeVaultWithdrawalNetwork": 0, + "l1FeeVaultWithdrawalNetwork": 0, + "baseFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "l1FeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "l2GenesisBlockGasLimit": "0x1c9c380", + "fundDevAccounts": false, + "gasPriceOracleOverhead": 188, + "gasPriceOracleScalar": 684000, + "eip1559Denominator": 50, + "eip1559Elasticity": 6, + "proxyAdmin": "0x8382dAbDc3837FE3cAC9817Fc799242d278BE9F6", + "proxyAdminOwner": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7", + "optimismBaseFeeRecipient": "0xba6fAD507A432402C64444Ed201025e060b34faB", + "optimismL1FeeRecipient": "0x91EFd7d4c6a2A04Ca59a05a4B8E07207D31a6589", + "l2CrossDomainMessengerOwner": "0x41E49D09792cF6281EbBbeb375571Ee0918D295B", + "gasPriceOracleOwner": "0x4FaE52EeB31e68BfF5e7Ea5634B1d9ABbC15927D", + "l2OutputOracleChallenger": "0x45eFFbD799Ab49122eeEAB75B78D9C56A187F9A7" +} diff --git a/validation/genesis/validation-inputs/999999999/meta.toml b/validation/genesis/validation-inputs/999999999/meta.toml new file mode 100644 index 000000000..b050f5169 --- /dev/null +++ b/validation/genesis/validation-inputs/999999999/meta.toml @@ -0,0 +1,4 @@ +genesis_creation_commit = "e40b268f28fdadb51c347795041dc994a97ce989" +monorepo_build_command = "pnpm" +node_version = "18.12.1" +genesis_creation_command = "opnode1" From 9012c0ddeded7d7d41dd90ba97ae39473a78d757 Mon Sep 17 00:00:00 2001 From: geoknee Date: Thu, 5 Sep 2024 10:47:09 +0100 Subject: [PATCH 25/30] add optimismConfig && just codegen --- superchain/configs/configs.json | 68 ++++++++++++++++++++++++ superchain/configs/mainnet/redstone.toml | 5 ++ 2 files changed, 73 insertions(+) diff --git a/superchain/configs/configs.json b/superchain/configs/configs.json index 8ba5812f1..4fd7414c5 100644 --- a/superchain/configs/configs.json +++ b/superchain/configs/configs.json @@ -215,6 +215,74 @@ "UnsafeBlockSigner": "0xDbad225D1C0DaBc27f6a9d250dBb136413C0DFb4" } }, + { + "Name": "Redstone", + "l2_chain_id": 690, + "PublicRPC": "https://rpc.redstonechain.com", + "SequencerRPC": "https://rpc.redstonechain.com", + "Explorer": "https://explorer.redstone.xyz", + "SuperchainLevel": 0, + "StandardChainCandidate": false, + "SuperchainTime": null, + "batch_inbox_address": "0xff00000000000000000000000000000000000690", + "Superchain": "mainnet", + "Chain": "redstone", + "canyon_time": 0, + "delta_time": 0, + "ecotone_time": 0, + "block_time": 2, + "seq_window_size": 3600, + "max_sequencer_drift": 600, + "DataAvailabilityType": "eth-da", + "optimism": { + "eip1559Elasticity": 6, + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250 + }, + "GasPayingToken": null, + "genesis": { + "L1": { + "Hash": "0xb9ec694afdde2e2ed661ed8ec56dace5cf8723801342fa1229e693f2a98af672", + "Number": 19578374 + }, + "L2": { + "Hash": "0xa4f55631013577464810893a05b18f07fe483885a6ef93e0060e7128bdf4ca3b", + "Number": 0 + }, + "l2_time": 1712185091, + "ExtraData": null, + "system_config": { + "batcherAddr": "0xA31cb9Bc414601171D4537580f98F66C03aECd43", + "overhead": "0x0000000000000000000000000000000000000000000000000000000000000001", + "scalar": "0x0000000000000000000000000000000000000000000000000000000000001def", + "gasLimit": 100000000 + } + }, + "Addresses": { + "AddressManager": "0xFe27f187A9E46104a932189dDF229871E06B22F8", + "AnchorStateRegistryProxy": "0xc51ac31BcEFB64D999AF10129Cb7693EeE7c1179", + "BatchSubmitter": "0xA31cb9Bc414601171D4537580f98F66C03aECd43", + "Challenger": "0xb356B146F1629c49C44344464F69BCDAfb4bb664", + "DelayedWETHProxy": "0xa130523fD22e2a9D78F8aB232b01ff552845B4A9", + "DisputeGameFactoryProxy": "0x8f68E849eaf8EB943536F9d1D49Ea9C9b5868b98", + "Guardian": "0xb356B146F1629c49C44344464F69BCDAfb4bb664", + "L1CrossDomainMessengerProxy": "0x592C1299e0F8331D81A28C0FC7352Da24eDB444a", + "L1ERC721BridgeProxy": "0x4FFB98dBC3086bA85d5E626a6EbC3D0d08533fF4", + "L1StandardBridgeProxy": "0xc473ca7E02af24c129c2eEf51F2aDf0411c1Df69", + "L2OutputOracleProxy": "0xa426A052f657AEEefc298b3B5c35a470e4739d69", + "MIPS": "0x66D6be83984e3F026B4a9e2D8Fb082ecDBd43648", + "OptimismMintableERC20FactoryProxy": "0x5f962474834Cf1981Df6232e4b6431d3d10cb71D", + "OptimismPortalProxy": "0xC7bCb0e8839a28A1cFadd1CF716de9016CdA51ae", + "PreimageOracle": "0xE7d0fE72637B3C949cd81c63A4Ff1fb23feeF3b2", + "Proposer": "0x4c465E58946145bb2BFC38833154f5A3B5728CF7", + "ProxyAdmin": "0xCC53b447aFe07926423aB96D5496b1af30485ED2", + "ProxyAdminOwner": "0x70FdbCb066eD3621647Ddf61A1f40aaC6058Bc89", + "SuperchainConfig": "0x4b5b41c240173191425F5928bc6bdd0d439331BB", + "SystemConfigOwner": "0xb356B146F1629c49C44344464F69BCDAfb4bb664", + "SystemConfigProxy": "0x8f2428F7189c0d92D1c4a5358903A8c80Ec6a69D", + "UnsafeBlockSigner": "0xA5bdf717af725a47Fd7378d3D9C833776951efa0" + } + }, { "Name": "Lyra Chain", "l2_chain_id": 957, diff --git a/superchain/configs/mainnet/redstone.toml b/superchain/configs/mainnet/redstone.toml index 5d5793553..9e8957393 100644 --- a/superchain/configs/mainnet/redstone.toml +++ b/superchain/configs/mainnet/redstone.toml @@ -13,6 +13,11 @@ seq_window_size = 3600 max_sequencer_drift = 600 data_availability_type = "eth-da" +[optimism] + eip1559_elasticity = 6 + eip1559_denominator = 50 + eip1559_denominator_canyon = 250 + [genesis] l2_time = 1712185091 [genesis.l1] From 387ec1cfd7eb68c219cd7e563cc1addd20a4a690 Mon Sep 17 00:00:00 2001 From: Vinod Damle Date: Thu, 5 Sep 2024 06:02:58 -0400 Subject: [PATCH 26/30] CI: Migrate scheduled workflows to scheduled pipeline jobs (#549) * CircleCI has two pipeline triggers named `nightly_build` and `hourly_build`. * Remove workflow triggers and configure jobs to run on scheduled pipeline triggers . Co-authored-by: Vinod Damle --- .circleci/continue_config.yml | 24 ++++++++++-------------- 1 file changed, 10 insertions(+), 14 deletions(-) diff --git a/.circleci/continue_config.yml b/.circleci/continue_config.yml index ebd8d8ab7..a3e7453e7 100644 --- a/.circleci/continue_config.yml +++ b/.circleci/continue_config.yml @@ -238,6 +238,11 @@ jobs: - run: echo "All golang-validate-genesis-allocs jobs suceeded" workflows: hourly: + # run workflow only when the hourly_build pipeline is triggered + when: + and: + - equal: [ scheduled_pipeline, << pipeline.trigger_source >> ] + - equal: [ hourly_build, << pipeline.schedule.name >> ] jobs: - golang-validate-all: context: @@ -246,26 +251,17 @@ workflows: - golang-test: context: - slack - triggers: - - schedule: - cron: "0 * * * *" - filters: - branches: - only: - - main nightly: + # run workflow only when the nightly_build pipeline is triggered + when: + and: + - equal: [ scheduled_pipeline, << pipeline.trigger_source >> ] + - equal: [ nightly_build, << pipeline.schedule.name >> ] jobs: - golang-promotion-test: context: - slack - oplabs-rpc-urls - triggers: - - schedule: - cron: "0 0 * * *" - filters: - branches: - only: - - main pr-checks: jobs: - golang-validate-genesis-allocs: From da991d91a32851595a13bd06e2000ee9fa5b6c86 Mon Sep 17 00:00:00 2001 From: Vinod Damle Date: Thu, 5 Sep 2024 16:08:46 -0400 Subject: [PATCH 27/30] Genesis alloc utility: increase buffer size for streaming output/errors (#551) default scan buffer size in bufio is 64k, which limits the max size of any token that can be scanned. Since diffs for the genesis alloc tool has to process large hex strings, we supply a larger buffer to ensure that output/errors are piped in its entirety. Co-authored-by: Vinod Damle --- validation/genesis/utils.go | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/validation/genesis/utils.go b/validation/genesis/utils.go index afef8272e..79f3a0f71 100644 --- a/validation/genesis/utils.go +++ b/validation/genesis/utils.go @@ -40,6 +40,15 @@ func mustExecuteCommandInDir(dir string, cmd *exec.Cmd) { func streamOutputToLogger(reader io.Reader, t *testing.T) { scanner := bufio.NewScanner(reader) + + // default scan buffer in bufio is 64k, which limits the max token size that + // can be scanned. Since we are handling allocs which contain large hex strings, + // the output of a diff must handle large tokens. + // Provide our own buffer per recommendation in bufio before calling Scan() + // ref: https://github.com/golang/go/blob/release-branch.go1.22/src/bufio/scan.go#L78-L82 + buf := [bufio.MaxScanTokenSize * 1000]byte{} + scanner.Buffer(buf[:], bufio.MaxScanTokenSize*1000) + for scanner.Scan() { t.Log(scanner.Text()) } From 23f8c6902d8adbb5e27398a181ecb32889c91165 Mon Sep 17 00:00:00 2001 From: George Knee Date: Fri, 6 Sep 2024 11:28:02 +0100 Subject: [PATCH 28/30] Move `L1SecurityConfigs` and `SuperchainConfig` tests from standard candidate to standard only category (#552) * bring subtest interface in line with others * move l1 securityconfigs test to standard-only remove exclusions * remove unecessary exclusions * tidy up the way we apply exclusions This is now handled in a single, central location. I introduced typing for subtests to make this very clear how to extend in future. * just lint-all * use type aliasing * revert to usual Go fn declarations * fix some stragglers --- validation/chainid-rpc_test.go | 1 - validation/exclusions_test.go | 26 +++------- validation/gas-token_test.go | 2 - validation/gpo-params_test.go | 2 - validation/key-handover_test.go | 3 +- validation/optimism-portal-2-params_test.go | 1 - validation/security-configs_test.go | 7 ++- validation/superchain-config_test.go | 1 - validation/superchain-genesis_test.go | 7 +-- validation/superchain-version_test.go | 3 -- validation/uniqueness_test.go | 2 - validation/validation_test.go | 55 +++++++++++++-------- 12 files changed, 47 insertions(+), 63 deletions(-) diff --git a/validation/chainid-rpc_test.go b/validation/chainid-rpc_test.go index 76257e9d9..d72a52ce2 100644 --- a/validation/chainid-rpc_test.go +++ b/validation/chainid-rpc_test.go @@ -10,7 +10,6 @@ import ( ) func testChainIDFromRPC(t *testing.T, chain *ChainConfig) { - skipIfExcluded(t, chain.ChainID) // Create an ethclient connection to the specified RPC URL client, err := ethclient.Dial(chain.PublicRPC) require.NoError(t, err, "Failed to connect to the Ethereum client at RPC url %s", chain.PublicRPC) diff --git a/validation/exclusions_test.go b/validation/exclusions_test.go index dae3ecffd..282f02276 100644 --- a/validation/exclusions_test.go +++ b/validation/exclusions_test.go @@ -5,7 +5,7 @@ import ( "testing" "time" - "github.com/ethereum-optimism/superchain-registry/superchain" + . "github.com/ethereum-optimism/superchain-registry/superchain" "github.com/stretchr/testify/require" ) @@ -39,25 +39,11 @@ var exclusions = map[string]map[uint64]bool{ 11763072: true, // sepolia-dev-0/base-devnet-0 No Public RPC declared }, UniquenessTest: { - 11155421: true, // oplabs devnet 0, not in upstream repo - 11763072: true, // base devnet 0, not in upstream repo} + 11155421: true, // sepolia-dev-0/oplabs-devnet-0 Not in https://github.com/ethereum-lists/chains + 11763072: true, // sepolia-dev-0/base-devnet-0 Not in https://github.com/ethereum-lists/chains }, // Standard Checks - L1SecurityConfigTest: { - 8453: true, // base (incorrect challenger, incorrect guardian) - 84532: true, // base-sepolia (incorrect challenger) - 7777777: true, // zora (incorrect challenger) - 1750: true, // metal (incorrect challenger) - 919: true, // mode sepolia (incorrect challenger) - 999999999: true, // zora sepolia (incorrect challenger) - 34443: true, // mode (incorrect challenger) - 1740: true, // metal-sepolia - }, - StandardContractVersionsTest: { - 11155421: true, // sepolia-dev0/oplabs-devnet-0 - 11763072: true, // sepolia-dev0/base-devnet-0 - }, OptimismPortal2ParamsTest: { 11763072: true, // sepolia-dev0/base-devnet-0 }, @@ -65,7 +51,7 @@ var exclusions = map[string]map[uint64]bool{ var silences = map[string]map[uint64]time.Time{ OptimismPortal2ParamsTest: { - 10: time.Unix(int64(*superchain.OPChains[10].HardForkConfiguration.GraniteTime), 0), // mainnet/op silenced until Granite activates + 10: time.Unix(int64(*OPChains[10].HardForkConfiguration.GraniteTime), 0), // mainnet/op silenced until Granite activates }, } @@ -77,8 +63,8 @@ func TestExclusions(t *testing.T) { continue } if v[k] { - require.NotNil(t, superchain.OPChains[k], k) - require.False(t, superchain.OPChains[k].SuperchainLevel == superchain.Standard, "Standard Chain %d may not be excluded from any check", k) + require.NotNil(t, OPChains[k], k) + require.False(t, OPChains[k].SuperchainLevel == Standard, "Standard Chain %d may not be excluded from any check", k) } } } diff --git a/validation/gas-token_test.go b/validation/gas-token_test.go index 0d072f075..f82522549 100644 --- a/validation/gas-token_test.go +++ b/validation/gas-token_test.go @@ -14,8 +14,6 @@ import ( ) func testGasToken(t *testing.T, chain *ChainConfig) { - skipIfExcluded(t, chain.ChainID) - client, err := ethclient.Dial(chain.PublicRPC) require.NoError(t, err, "Failed to connect to the Ethereum client at RPC url %s", chain.PublicRPC) defer client.Close() diff --git a/validation/gpo-params_test.go b/validation/gpo-params_test.go index 418ae8213..295432cc0 100644 --- a/validation/gpo-params_test.go +++ b/validation/gpo-params_test.go @@ -18,8 +18,6 @@ import ( ) func testGasPriceOracleParams(t *testing.T, chain *ChainConfig) { - skipIfExcluded(t, chain.ChainID) - gasPriceOraclAddr := common.HexToAddress("0x420000000000000000000000000000000000000F") checkPreEcotoneResourceConfig := func(t *testing.T, chain *ChainConfig, client *ethclient.Client) { diff --git a/validation/key-handover_test.go b/validation/key-handover_test.go index 05e831a48..2d65cf7c1 100644 --- a/validation/key-handover_test.go +++ b/validation/key-handover_test.go @@ -9,7 +9,8 @@ import ( "github.com/stretchr/testify/require" ) -func testKeyHandover(t *testing.T, chainID uint64) { +func testKeyHandover(t *testing.T, chain *ChainConfig) { + chainID := chain.ChainID superchain := OPChains[chainID].Superchain rpcEndpoint := Superchains[superchain].Config.L1.PublicRPC require.NotEmpty(t, rpcEndpoint, "no rpc specified") diff --git a/validation/optimism-portal-2-params_test.go b/validation/optimism-portal-2-params_test.go index 86eef2686..40995c35d 100644 --- a/validation/optimism-portal-2-params_test.go +++ b/validation/optimism-portal-2-params_test.go @@ -16,7 +16,6 @@ import ( ) func testOptimismPortal2Params(t *testing.T, chain *ChainConfig) { - skipIfExcluded(t, chain.ChainID) opAddr, err := Addresses[chain.ChainID].AddressFor("OptimismPortalProxy") require.NoError(t, err) diff --git a/validation/security-configs_test.go b/validation/security-configs_test.go index d059dbd04..4d773534c 100644 --- a/validation/security-configs_test.go +++ b/validation/security-configs_test.go @@ -53,10 +53,10 @@ var checkResolutions = func(t *testing.T, r standard.Resolutions, chainID uint64 } } -func testL1SecurityConfig(t *testing.T, chainID uint64) { - skipIfExcluded(t, chainID) +func testL1SecurityConfig(t *testing.T, chain *ChainConfig) { + chainID := chain.ChainID - rpcEndpoint := Superchains[OPChains[chainID].Superchain].Config.L1.PublicRPC + rpcEndpoint := Superchains[chain.Superchain].Config.L1.PublicRPC require.NotEmpty(t, rpcEndpoint, "no rpc specified") client, err := ethclient.Dial(rpcEndpoint) @@ -97,7 +97,6 @@ func testL1SecurityConfig(t *testing.T, chainID uint64) { } func testL2SecurityConfig(t *testing.T, chain *ChainConfig) { - skipIfExcluded(t, chain.ChainID) // Create an ethclient connection to the specified RPC URL client, err := ethclient.Dial(chain.PublicRPC) require.NoError(t, err, "Failed to connect to the Ethereum client at RPC url %s", chain.PublicRPC) diff --git a/validation/superchain-config_test.go b/validation/superchain-config_test.go index 0157d1ce8..a88ca7458 100644 --- a/validation/superchain-config_test.go +++ b/validation/superchain-config_test.go @@ -9,7 +9,6 @@ import ( ) func testSuperchainConfig(t *testing.T, chain *ChainConfig) { - skipIfExcluded(t, chain.ChainID) expected := Superchains[chain.Superchain].Config.SuperchainConfigAddr require.NotNil(t, expected, "Superchain does not declare a superchain_config_addr") diff --git a/validation/superchain-genesis_test.go b/validation/superchain-genesis_test.go index e065ea245..5235c0a18 100644 --- a/validation/superchain-genesis_test.go +++ b/validation/superchain-genesis_test.go @@ -14,9 +14,8 @@ import ( "github.com/stretchr/testify/require" ) -func testGenesisHash(t *testing.T, chainID uint64) { - skipIfExcluded(t, chainID) - +func testGenesisHash(t *testing.T, chain *ChainConfig) { + chainID := chain.ChainID chainConfig, ok := OPChains[chainID] if !ok { t.Fatalf("no chain with ID %d found", chainID) @@ -37,8 +36,6 @@ func testGenesisHash(t *testing.T, chainID uint64) { } func testGenesisHashAgainstRPC(t *testing.T, chain *ChainConfig) { - skipIfExcluded(t, chain.ChainID) - declaredGenesisHash := chain.Genesis.L2.Hash rpcEndpoint := chain.PublicRPC diff --git a/validation/superchain-version_test.go b/validation/superchain-version_test.go index 5e15abb82..78700b07b 100644 --- a/validation/superchain-version_test.go +++ b/validation/superchain-version_test.go @@ -43,9 +43,6 @@ var contractsToCheckVersionAndBytecodeOf = []string{ func testContractsMatchATag(t *testing.T, chain *ChainConfig) { // list of contracts to check for version/bytecode uniformity - - skipIfExcluded(t, chain.ChainID) - rpcEndpoint := Superchains[chain.Superchain].Config.L1.PublicRPC require.NotEmpty(t, rpcEndpoint) diff --git a/validation/uniqueness_test.go b/validation/uniqueness_test.go index 656b39ef9..c11771437 100644 --- a/validation/uniqueness_test.go +++ b/validation/uniqueness_test.go @@ -118,8 +118,6 @@ func init() { } func testIsGloballyUnique(t *testing.T, chain *ChainConfig) { - skipIfExcluded(t, chain.ChainID) - props := globalChainIds[uint(chain.ChainID)] require.NotNil(t, props, "chain ID is not listed at chainid.network") globalChainName := props.Name diff --git a/validation/validation_test.go b/validation/validation_test.go index 266094bd5..413862c51 100644 --- a/validation/validation_test.go +++ b/validation/validation_test.go @@ -30,6 +30,19 @@ const ( GenesisAllocsMetadataTest = "Genesis_Allocs_Metadata" ) +type ( + subTest = func(t *testing.T) + subTestForChain = func(t *testing.T, chain *ChainConfig) +) + +// applyExclusions is a higher order function which returns a subtest function with exclusions applied +func applyExclusions(chain *ChainConfig, f subTestForChain) subTest { + return func(t *testing.T) { + skipIfExcluded(t, chain.ChainID) + f(t, chain) + } +} + func TestValidation(t *testing.T) { // Entry point for validation checks which run // on each OP chain. @@ -61,40 +74,40 @@ func testValidation(t *testing.T, chain *ChainConfig) { // designed to protect downstream software or // sanity checking basic consistency conditions. func testUniversal(t *testing.T, chain *ChainConfig) { - t.Run(GenesisHashTest, func(t *testing.T) { testGenesisHash(t, chain.ChainID) }) - t.Run(GenesisRPCTest, func(t *testing.T) { testGenesisHashAgainstRPC(t, chain) }) - t.Run(UniquenessTest, func(t *testing.T) { testIsGloballyUnique(t, chain) }) - t.Run(ChainIDRPCTest, func(t *testing.T) { testChainIDFromRPC(t, chain) }) - t.Run(OptimismConfigTest, func(t *testing.T) { testOptimismConfig(t, chain) }) + t.Run(GenesisHashTest, applyExclusions(chain, testGenesisHash)) + t.Run(GenesisRPCTest, applyExclusions(chain, testGenesisHashAgainstRPC)) + t.Run(UniquenessTest, applyExclusions(chain, testIsGloballyUnique)) + t.Run(ChainIDRPCTest, applyExclusions(chain, testChainIDFromRPC)) + t.Run(OptimismConfigTest, applyExclusions(chain, testOptimismConfig)) } // testStandardCandidate applies to Standard and Standard Candidate Chains. func testStandardCandidate(t *testing.T, chain *ChainConfig) { // Standard Config Params - t.Run(RollupConfigTest, func(t *testing.T) { testRollupConfig(t, chain) }) - t.Run(GasTokenTest, func(t *testing.T) { testGasToken(t, chain) }) - t.Run(ResourceConfigTest, func(t *testing.T) { testResourceConfig(t, chain) }) - t.Run(GasLimitTest, func(t *testing.T) { testGasLimit(t, chain) }) - t.Run(GPOParamsTest, func(t *testing.T) { testGasPriceOracleParams(t, chain) }) - t.Run(StartBlockRPCTest, func(t *testing.T) { testStartBlock(t, chain) }) - t.Run(SuperchainConfigTest, func(t *testing.T) { testSuperchainConfig(t, chain) }) + t.Run(RollupConfigTest, applyExclusions(chain, testRollupConfig)) + t.Run(GasTokenTest, applyExclusions(chain, testGasToken)) + t.Run(ResourceConfigTest, applyExclusions(chain, testResourceConfig)) + t.Run(GasLimitTest, applyExclusions(chain, testGasLimit)) + t.Run(GPOParamsTest, applyExclusions(chain, testGasPriceOracleParams)) + t.Run(StartBlockRPCTest, applyExclusions(chain, testStartBlock)) // Standard Config Roles - t.Run(L1SecurityConfigTest, func(t *testing.T) { testL1SecurityConfig(t, chain.ChainID) }) - t.Run(L2SecurityConfigTest, func(t *testing.T) { testL2SecurityConfig(t, chain) }) + t.Run(L2SecurityConfigTest, applyExclusions(chain, testL2SecurityConfig)) // Other - t.Run(DataAvailabilityTypeTest, func(t *testing.T) { testDataAvailabilityType(t, chain) }) - t.Run(GenesisAllocsMetadataTest, func(t *testing.T) { testGenesisAllocsMetadata(t, chain) }) + t.Run(DataAvailabilityTypeTest, applyExclusions(chain, testDataAvailabilityType)) + t.Run(GenesisAllocsMetadataTest, applyExclusions(chain, testGenesisAllocsMetadata)) } // testStandard should be applied only to a fully Standard Chain, // i.e. not to a Standard Candidate Chain. func testStandard(t *testing.T, chain *ChainConfig) { + // Standard Config Params + t.Run(SuperchainConfigTest, applyExclusions(chain, testSuperchainConfig)) // Standard Contract Versions - t.Run(StandardContractVersionsTest, func(t *testing.T) { - testContractsMatchATag(t, chain) - }) + t.Run(StandardContractVersionsTest, applyExclusions(chain, testContractsMatchATag)) + // Standard Config Roles + t.Run(L1SecurityConfigTest, applyExclusions(chain, testL1SecurityConfig)) // Standard Config Params - t.Run(OptimismPortal2ParamsTest, func(t *testing.T) { testOptimismPortal2Params(t, chain) }) + t.Run(OptimismPortal2ParamsTest, applyExclusions(chain, testOptimismPortal2Params)) // Standard Config Roles - t.Run(KeyHandoverTest, func(t *testing.T) { testKeyHandover(t, chain.ChainID) }) + t.Run(KeyHandoverTest, applyExclusions(chain, testKeyHandover)) } From 221dea9e7f3ce66cd95fffdbc01bba920cbc664b Mon Sep 17 00:00:00 2001 From: geoknee Date: Mon, 9 Sep 2024 10:04:27 +0100 Subject: [PATCH 29/30] modify optimism params for redstone --- superchain/configs/mainnet/redstone.toml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/superchain/configs/mainnet/redstone.toml b/superchain/configs/mainnet/redstone.toml index 9e8957393..17d797028 100644 --- a/superchain/configs/mainnet/redstone.toml +++ b/superchain/configs/mainnet/redstone.toml @@ -11,12 +11,11 @@ ecotone_time = 0 # Thu 1 Jan 1970 00:00:00 UTC block_time = 2 seq_window_size = 3600 max_sequencer_drift = 600 -data_availability_type = "eth-da" [optimism] - eip1559_elasticity = 6 + eip1559_elasticity = 2 eip1559_denominator = 50 - eip1559_denominator_canyon = 250 + eip1559_denominator_canyon = 50 [genesis] l2_time = 1712185091 From 467e8d837da5f61e666b47dfe091c173bc623461 Mon Sep 17 00:00:00 2001 From: geoknee Date: Mon, 9 Sep 2024 10:11:12 +0100 Subject: [PATCH 30/30] migrate redstone's rollup.json and rerun just add-chain migrated to new "alt-da" scheme https://docs.optimism.io/builders/chain-operators/features/alt-da-mode#modify-rollupjson-config --- chainList.json | 2 +- chainList.toml | 2 +- superchain/configs/configs.json | 12 +++++++++--- superchain/configs/mainnet/redstone.toml | 7 +++++++ superchain/extra/addresses/addresses.json | 1 + 5 files changed, 19 insertions(+), 5 deletions(-) diff --git a/chainList.json b/chainList.json index 243c5b8f5..554503600 100644 --- a/chainList.json +++ b/chainList.json @@ -129,7 +129,7 @@ "https://explorer.redstone.xyz" ], "superchainLevel": 0, - "dataAvailabilityType": "eth-da", + "dataAvailabilityType": "alt-da", "parent": { "type": "L2", "chain": "mainnet" diff --git a/chainList.toml b/chainList.toml index f481d5e06..1f6a96ddc 100644 --- a/chainList.toml +++ b/chainList.toml @@ -89,7 +89,7 @@ rpc = ["https://rpc.redstonechain.com"] explorers = ["https://explorer.redstone.xyz"] superchain_level = 0 - data_availability_type = "eth-da" + data_availability_type = "alt-da" [chains.parent] type = "L2" chain = "mainnet" diff --git a/superchain/configs/configs.json b/superchain/configs/configs.json index 4fd7414c5..a2d840698 100644 --- a/superchain/configs/configs.json +++ b/superchain/configs/configs.json @@ -233,11 +233,16 @@ "block_time": 2, "seq_window_size": 3600, "max_sequencer_drift": 600, - "DataAvailabilityType": "eth-da", + "DataAvailabilityType": "alt-da", "optimism": { - "eip1559Elasticity": 6, + "eip1559Elasticity": 2, "eip1559Denominator": 50, - "eip1559DenominatorCanyon": 250 + "eip1559DenominatorCanyon": 50 + }, + "alt_da": { + "da_challenge_contract_address": "0x97A2dA87d3439b172e6DD027220e01c9Cb565B80", + "da_challenge_window": 3600, + "da_resolve_window": 3600 }, "GasPayingToken": null, "genesis": { @@ -263,6 +268,7 @@ "AnchorStateRegistryProxy": "0xc51ac31BcEFB64D999AF10129Cb7693EeE7c1179", "BatchSubmitter": "0xA31cb9Bc414601171D4537580f98F66C03aECd43", "Challenger": "0xb356B146F1629c49C44344464F69BCDAfb4bb664", + "DAChallengeAddress": "0x97A2dA87d3439b172e6DD027220e01c9Cb565B80", "DelayedWETHProxy": "0xa130523fD22e2a9D78F8aB232b01ff552845B4A9", "DisputeGameFactoryProxy": "0x8f68E849eaf8EB943536F9d1D49Ea9C9b5868b98", "Guardian": "0xb356B146F1629c49C44344464F69BCDAfb4bb664", diff --git a/superchain/configs/mainnet/redstone.toml b/superchain/configs/mainnet/redstone.toml index 17d797028..204c358f2 100644 --- a/superchain/configs/mainnet/redstone.toml +++ b/superchain/configs/mainnet/redstone.toml @@ -11,12 +11,18 @@ ecotone_time = 0 # Thu 1 Jan 1970 00:00:00 UTC block_time = 2 seq_window_size = 3600 max_sequencer_drift = 600 +data_availability_type = "alt-da" [optimism] eip1559_elasticity = 2 eip1559_denominator = 50 eip1559_denominator_canyon = 50 +[alt_da] + da_challenge_contract_address = "0x97A2dA87d3439b172e6DD027220e01c9Cb565B80" + da_challenge_window = 3600 + da_resolve_window = 3600 + [genesis] l2_time = 1712185091 [genesis.l1] @@ -54,3 +60,4 @@ max_sequencer_drift = 600 DisputeGameFactoryProxy = "0x8f68E849eaf8EB943536F9d1D49Ea9C9b5868b98" MIPS = "0x66D6be83984e3F026B4a9e2D8Fb082ecDBd43648" PreimageOracle = "0xE7d0fE72637B3C949cd81c63A4Ff1fb23feeF3b2" + DAChallengeAddress = "0x97A2dA87d3439b172e6DD027220e01c9Cb565B80" diff --git a/superchain/extra/addresses/addresses.json b/superchain/extra/addresses/addresses.json index 938f4ec6e..aa00cfdb8 100644 --- a/superchain/extra/addresses/addresses.json +++ b/superchain/extra/addresses/addresses.json @@ -226,6 +226,7 @@ "AnchorStateRegistryProxy": "0xc51ac31BcEFB64D999AF10129Cb7693EeE7c1179", "BatchSubmitter": "0xA31cb9Bc414601171D4537580f98F66C03aECd43", "Challenger": "0xb356B146F1629c49C44344464F69BCDAfb4bb664", + "DAChallengeAddress": "0x97A2dA87d3439b172e6DD027220e01c9Cb565B80", "DelayedWETHProxy": "0xa130523fD22e2a9D78F8aB232b01ff552845B4A9", "DisputeGameFactoryProxy": "0x8f68E849eaf8EB943536F9d1D49Ea9C9b5868b98", "Guardian": "0xb356B146F1629c49C44344464F69BCDAfb4bb664",